How should I get current image resource of an imageButton? I need something like this:
imageButton.getImageResource();
Thanks a lot
I think you can't, current API doesn't allow this. But if you really need this, you can do something like this:
imageButton.setImageResource(R.drawable.your_resource);
imageButton.setTag(R.drawable.your_resource);
//
// somewhere later...
//
Integer resource = (Integer)imageButton.getTag();