I wrote an android library for some UI utilities. I have a function that return ImageView. But, my problem is that I want that the resource of the drawable image, will be in the project that contains the library. I will explain...
I want that the ImageView will always take the drawable with the source name: R.drawable.ic_img_logo
(and only this name). This resource will not actually be in the library. But the project that contains the library will contains also drawable with the resource name R.drawable.ic_img_logo
.
I know that this thing works with id (of views), you can create file call ids.xml
and define some ids in the file that others can use them, and you will recognize them.
But how can I do this with drawables?