title: How to set a button background and back according to selected state not pressed state
body: <p>I currently have a sound button,and I would like to change its background every time when it's selected and clicked(I'm developing on a pair of android glasses, so when the button is selected it's not pressed, thus two different states).</p>
  
  <p>I have used the xml file to change button background when selected so far:
  </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:drawable="@drawable/no_music"
          android:state_selected="true" /&gt;
      &lt;item android:drawable="@drawable/no_music"
          android:state_focused="true" /&gt;
      &lt;item android:drawable="@drawable/music" /&gt;
  &lt;/selector&gt;
  </code></pre>
  
  <p>And together in the <code>onClick</code> method of the button, I set the button background according to the state:</p>
  
  <pre><code>public void musicPlay(View view) {
      Button music = (Button) findViewById(R.id.music);
          if(isPlaying) {
              music.setBackgroundResource(R.drawable.no_music);
              MusicManager.release()
          }else{
              music.setBackgroundResource(R.drawable.music);
              MusicManager.start(this);
          }
      isPlaying = !isPlaying;
  }
  </code></pre>
  
  <p>When I click the button, each time it would change its background. But when I select it, it would only change background once. Is there any method that I can use to make selected state the same as the pressed one? </p>
  
  <p>Thank you very much.</p>