Both, at least that's what my rats say. If I have dry skin, a band aid or any other bad thing on my skin they would like to help remove that. If I have something yummy on my skin they will help remove that too, but that's because it is yummy and should be removed. things that don't taste good, are still removed, like a band aid and then dropped immediately...cus yuck. I would say they need to trust you either way. A rat who is scared of humans usually won't even take a treat from you. So my opinion if they take treats, they are starting to trust you, if they are grooming you they trust you even more.
Grooming is a sign of love and contentment. In their own colonies, rats mutually groom each other as a sign of affection. A grooming rat is generally one that trusts and likes you. Of course, if you have just eaten something, they may also be trying to lick at the remains of deliciousness on your fingers.