Android: Create TextView that flashes when clicked
- by Jeremy
How do I set up a TextView to flash when it is clicked? I essentially want one of the objects that is displayed in a ListActivity, but inside a normal View.
I have tried to do this by adding an OnClickListener, but what I really need is something like adding an On(Un)SelectListener. Using the onClickListener, I can change the TextView background, but obviously the background stays that color. I thought of using a new Handler().postDelayed(new Runnable(){ ... }) kind of thing to reset the backround after some small time, but I did not know if this would be overkill for what I'm trying to do.
What would you recommend?