Is it possible to create an xml subclass of a state list selector?
<p>For example, say I have a color state list declared in XML, called <strong>example1.xml</strong></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:color="@color/red"
        android:state_pressed="true" /&gt;

    &lt;item
        android:color="@color/blue"
        android:state_checked="true" /&gt;

    &lt;item
        android:color="@color/green"
        android:state_disabled="true" /&gt;

    &lt;item
        android:color="@color/orange" /&gt;
&lt;/selector&gt;
</code></pre>

<p>Then, I want to create <strong>example2.xml</strong> and I want it to be the exact same as <strong>example1.xml</strong> except I want the pressed color to be purple instead of red:</p>

<pre><code>    &lt;item
        android:color="@color/purple"
        android:state_pressed="true" /&gt;
</code></pre>

<p>So <strong>example2.xml</strong> would end up acting like this:</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:color="@color/purple" &lt;-- note this value is different
            android:state_pressed="true" /&gt;

        &lt;item
            android:color="@color/blue"
            android:state_checked="true" /&gt;

        &lt;item
            android:color="@color/green"
            android:state_disabled="true" /&gt;

        &lt;item
            android:color="@color/orange" /&gt;
    &lt;/selector&gt;
</code></pre>

<p>but without all of the duplicate code. Also, if I want to change a color I can just change it in one place.</p>

<p>Is this possible?</p>
