Dianne Hackborn be1f62260a Fix issue #3374356: Buttons sometimes don't highlight
On touch up, View would move itself to the pressed state if it
hadn't already shown as pressed.  However, it did this *after*
scheduling the message to deliver the onClick().  Thus if the
app took a little too long to execute inside of onClick(), the
invalidate to draw the highlight state would be executed right
before the following message to remove the highlight state,
causing it to basically not be shown.

This change just does the invalidate before scheduling the
onClick, so we can be sure it gets done first.

Change-Id: I6a4d1742a3aab60969c38b44bb3e163f48de62d4
2011-01-20 15:24:28 -08:00
..