title: How to use Android Spinner like a drop-down list
body: <p>It's taken me quite a while to get my head around the Android Spinner. After several failed implementation attempts, and after reading many questions partially similar to my own but <a href="https://stackoverflow.com/questions/2373948/ignore-onitemselectedlistener-firing-on-create">without satisfactory answers</a>, and some without any answers at all, e.g. <a href="https://stackoverflow.com/questions/6788664/android-spinner-onitemselectedlistener-not-working-accurately">here</a> and <a href="https://stackoverflow.com/questions/7043183/onitemselectedlistener-only-triggered-if-selection-actually-change">here</a>, I finally get that a "spinner" in Android isn't meant to be the same thing as a "drop-down list" from desktop apps, or a select in HTML. However, what my app (and I'm guessing the apps of all the other posters whose questions are similar) needs is something that works like a drop-down box, not like a spinner.</p>
  
  <p>My two problems are with what I first considered to be idiosynchrasies the OnItemSelectedListener (I've seen these as separate questions on this site but not as one):</p>
  
  <ol>
  <li>An initial selection of the first list item is triggered automatically without the user's interaction.</li>
  <li>When the item that was already selected is selected again by the user, it is ignored.</li>
  </ol>
  
  <p>Now I realise that, when you think about it, it makes sense for this to happen on a <em>spinner</em> - it has to start with a default value selected, and you spin it only to change that value, not to "re-select" a value - <a href="http://developer.android.com/reference/android/widget/AdapterView.OnItemSelectedListener.html" rel="nofollow noreferrer">the documentation</a> actually says: "This callback is invoked only when the newly selected position is different from the previously selected position". And I've seen <a href="https://stackoverflow.com/questions/4206047/android-spinner-how-may-i-distinguish-users-actions-from-computers-actions">answers suggesting that you set up a flag</a> to ignore the first automatic selection - I guess I could live with that if there's no other way.</p>
  
  <p>But since what I really want is a drop-down list which behaves as a drop-down list should (and as users can and should expect), what I need is something <em>like</em> a Spinner that behaves like a drop-down, like a combo-box. I don't care about any automatic pre-selection (that should happen without triggering my listener), and I want to know about <em>every</em> selection, even if it's the same one as previously (after all, the user <em>selected</em> the same item again).</p>
  
  <p>So... is there something in Android that can do that, or some workaround to make a Spinner behave like a drop-down list? If there <em>is</em> a question like this one on this site that I haven't found, and which has a satisfactory answer, please let me know (in which case I sincerely apologise for repeating the question).</p>