How can I get (int) resource-id of specific density (hdpi, xhdpi, etc) of the app-icon in Android?
I know we can get drawable object of specific density using getDrawableForDensity() method, but how to get resource id of this drawable?
How can I get (int) resource-id of specific density (hdpi, xhdpi, etc) of the app-icon in Android?
I know we can get drawable object of specific density using getDrawableForDensity() method, but how to get resource id of this drawable?
Copyright © 2021 Jogjafile Inc.
Android doesn't need you to do this. Each device density is automatically referenced once you add the resources. However, you should use vector drawables where necessary.