I am using Drawable.getConstantState to compare two drawables as mentioned here but couldnt understand its purpose. In the docs, its given that
Return a Drawable.ConstantState instance that holds the shared state of this Drawable
Which shared state?
Also, Drawable.ConstantState
is used by Drawables to store shared constant state and data between Drawables
So i dont understand which shared state here and what data is stored? And how does it help in comparing the drawables.