Update preload list, clean up drawable theming

Removes all implementations of three-arg ConstantState constructor, since
we handle mutation and applyTheme() in Resources now. Moves progress bar
tinting to android:tint attribute. Correctly implements applyTheme() and
canApplyTheme() in all drawable wrapper and container classes.

Change-Id: Ic9cb43d0d6228aa4914f3124bed234b837beaa41
This commit is contained in:
Alan Viverette
2014-10-14 14:07:21 -07:00
parent 2f82e48abb
commit 17cd4dfe3a
22 changed files with 333 additions and 402 deletions

View File

@@ -128,6 +128,26 @@ public class ScaleDrawable extends Drawable implements Drawable.Callback {
}
}
@Override
public void applyTheme(Theme t) {
super.applyTheme(t);
final ScaleState state = mScaleState;
if (state == null) {
return;
}
if (state.mDrawable != null) {
state.mDrawable.applyTheme(t);
}
}
@Override
public boolean canApplyTheme() {
final ScaleState state = mScaleState;
return state != null && state.mDrawable != null && state.mDrawable.canApplyTheme();
}
// overrides from Drawable.Callback
public void invalidateDrawable(Drawable who) {