How to identify an imageview drawable?
<p>There's an <code>ImageView</code> in my app with a drawable that can be changed by the user and a black <code>TextView</code> over it. If the user changes this image to one with a black background, he won't be able to see the text.</p>

<p>How can I identify if the image resource is <code>R.drawable.imageA</code> so I can set the text a different color?</p>

<p>I thought about setting a tag for the <code>ImageView</code>, but then I would have to set it for each option, when there's only two options I care about.</p>

<p>I tried:</p>

<pre><code>if (imageview.getDrawable.equals(R.drawable.imageA)) {
    textView.setText(Color.WHITE);
    }
</code></pre>

<p>Also tried with <code>getResource</code>, but neither worked.</p>
