title: How can I make selector for an imageview to change only the background but not the image source?
body: <p>I have an ImageView with both image src and background color set.</p>
  
  <p>This image is into a layout that is the gridview item layout.</p>
  
  <p>I would to create an xml selector that when the item is choosen, the image background change, but the image src not.</p>
  
  <p>Something similar to the main menu of android with icon with text, I want to highlight only the image.</p>
  
  <p>I would not to make an image for each state of the object, I only want to change the background.</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="match_parent"
      android:layout_height="match_parent" &gt;
  
      &lt;ImageView
          android:id="@+id/img_0"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_alignParentTop="true"
          android:layout_centerHorizontal="true"
          android:layout_marginTop="30dp"
          android:background="@drawable/selector_categorie"
          android:src="@drawable/ic_launcher"/&gt;
  
      &lt;TextView
          android:id="@+id/text_1"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:layout_below="@+id/img_0"
          android:layout_centerHorizontal="true"
          android:layout_marginTop="15dp"
          android:gravity="center"
          android:textAppearance="?android:attr/textAppearanceLarge" /&gt;
  
      &lt;TextView
          android:id="@+id/text_2"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:layout_below="@+id/text_1"
          android:layout_marginTop="15dp"
          android:gravity="center"
          android:textAppearance="?android:attr/textAppearanceMedium" /&gt;
  
      &lt;TextView
          android:id="@+id/text_3"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          android:layout_below="@+id/text_2"
          android:layout_marginTop="15dp"
          android:gravity="center"
          android:textAppearance="?android:attr/textAppearanceMedium" /&gt;
  
  
  &lt;/RelativeLayout&gt;
  </code></pre>