This question is quite old, but I still give an answer.
When you go to the v7 support library, you need to change the listener.
public class YourActivity extends AppCompatActivity implements AdapterView.OnItemSelectedListener
Spinner Creation
Spinner spinner = (Spinner) findViewById(R.id.spinner);
spinner.setOnItemSelectedListener(this);
Implement listener methods
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
Snackbar.make(this.getCurrentFocus(), "OnItemSelected", Snackbar.LENGTH_LONG);
}
@Override
public void onNothingSelected(AdapterView<?> parent) {
Snackbar.make(this.getCurrentFocus(), "onNothingSelected", Snackbar.LENGTH_LONG);
}
onNothingSelected method used is not clear. You can read this article to clarify.
, .