3

I have a listview of different view types, including spinners and edittexts. I have a single focuslistener that listens for the onfocus lost event as I have to do some post processing. As a user may have to switch from one edittext to a next edittext by touch, and calling notifydatachanged in my focus lost event would trigger a redraw of the views, I used a variable to set the last focused edittext(whenever an edittext gains focus) so that I can requestfocus for the appropriate edittext in the getview call of the adapter.

Observation: If the spinners are touched first, they work fine. However if they are touched after any of the edittext has been focused and input with values, the spinners will not set the selected item on being touched.

Is anyone able to explain this observation or suggest a workaround?

Yury
  • 20,618
  • 7
  • 58
  • 86
g t
  • 263
  • 1
  • 2
  • 4

0 Answers0