title: android:state_selected not working
body: <p>I just want to change the image on button click using the selector in the XML file. <code>android:state_pressed="true"</code> is working while <code>android:state_selected="true"</code> not working.
  Here is my xml code:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;selector xmlns:android="http://schemas.android.com/apk/res/android"&gt;
      &lt;item
          android:state_selected="true"
          android:state_checked="false"
          android:state_focused="false"
          android:state_pressed="false"
          android:drawable="@drawable/discount1"/&gt;
      &lt;item
          android:state_pressed="true"
          android:drawable="@drawable/discount1"/&gt;
      &lt;item
          android:drawable="@drawable/discount2"/&gt;
  &lt;/selector&gt;
  </code></pre>
  
  <p>Here is activity_main.xml:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context="com.example.democoordinatorlayout.MainActivity"&gt;
  
      &lt;Button
          android:id="@+id/button1"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_alignParentBottom="true"
          android:background="@drawable/buttonselector"
           /&gt;
  &lt;/RelativeLayout&gt;
  </code></pre>