Skip to content Skip to sidebar Skip to footer

Android Spinner: How To Catch When User Exits Spinner Leaving Selected Value As-is?

When a spinner comes up, it usually has a value preselected. If the users explicitly selects another item, my onClickItem handler is getting called. But i did not find a way to de

Solution 1:

The user can exit the spinner's dialog by pressing the hardware back key. That's what the key is for - to back out of activities and dialogs. If the currently selected item is selected, that also exits the spinner's dialog. There's generally no need for special handling to allow cancelling the selection, since the the user can directly exit the spinner dialog without making a selection.


Post a Comment for "Android Spinner: How To Catch When User Exits Spinner Leaving Selected Value As-is?"