Android - using int value 0 as "null"-equivalent for R.drawable
<p>I'm using an intuitive but perhaps unorthodox shortcut, and I quite simply want to know if it may cause problems, is bad form, or if there is a different, more accepted way of doing it.</p>

<p>The shortcut is: in a function which expects an int which is an R.drawable constant, I sometimes use a 0 to act as an equivalent to passing "null".</p>

<p>Here's a sort of template of how I use this:</p>

<p><code>    int someDrawable = isSomeCondition() ? R.drawable.somedrawable_identifier : 0;
    mHandler.post(new UpdateSomeUI(someDrawable));</p>

<pre><code>//and, elsewhere in the application,
private class UpdateSomeUI implements Runnable {
    private final int someDrawable;

    public UpdateSomeUI(int someDrawable) {
        this.someDrawable = someDrawable;
    }

    public void run() {
        mSomeImageView.setImageResource(someDrawable);
    }
}
</code></pre>

<p></code></p>

<p>It seems to work - that is, so far it's been doing what I want, and so far I have observed no adverse effects like crashes or the creation of quantum singularities within the device.</p>

<p>Is this safe to do?
Is this bad form?
I S'dTFW for some official integer value that would be recognized as "null" in this sort of circumstance, but came up empty. Does anyone know if such a value exists?</p>

<p>Edit:
I realize that the tag "r" isn't referring to the one I want. The tag "android.R" doesn't seem to exist, however. I guess I'll remove the tag for now.</p>
