Get ToggleButton drawable from selector
<p>I have a ToggleButton that uses a selector to choose between 2 images (checked and unchecked).</p>

<pre><code>&lt;selector xmlns:android="http://schemas.android.com/apk/res/android"&gt;
    &lt;item android:state_checked="true"
          android:drawable="@drawable/img_piece1" /&gt; &lt;!-- pressed --&gt;
    &lt;item     android:drawable="@drawable/img_piece2" /&gt; &lt;!-- default/unchecked --&gt;
&lt;/selector&gt;
</code></pre>

<p>Is there a way to retrieve the current drawable resource (checked/unchecked) of the toggle button in code? I tried using the ToggleButton.getBackground(), however this only seems to return the default Drawable always.</p>
