Sometimes I do it when I like the girl. I'm usually scanning her face while I think "crap, what part of the face do people stare at when they aren't attracted to each other?"
Other times I'm either waiting for her, or anyone in this situation, to say something. I also do it when her lips are unique in some way. Not necessarily because I like her, or thinking about kissing them. There are times when they are very pretty and eye-catching, and I think about how fun they would be to kiss.