java - Android: Adding a Drawable to an existing LayerDrawable -
i have layerdrawable construct array of drawables of 5 drawables. let’s in run-time want add drawable layerdrawable, in response event. how do without having re-create layerdrawable, time array of drawables of 6 drawables? thanks.
after layerdrawable created, new drawables can not added it.
see source of layerdrawable: array of drawables saved in mlayerstate.mchildren
, set in constructor.
however, setdrawablebylayerid(..)
can used exchange existing drawable new one.
Comments
Post a Comment