Add the ability to autoStart AID from xml
Bug: 73529437 Test: Ic818bbf1091d12631aedd6475d225fa4a708b29c Change-Id: I4807409895a057e775bfee5dea407e8dc1af94be
This commit is contained in:
@@ -261,6 +261,12 @@ public class AnimatedImageDrawable extends Drawable implements Animatable2 {
|
||||
if (repeatCount != REPEAT_UNDEFINED) {
|
||||
this.setRepeatCount(repeatCount);
|
||||
}
|
||||
|
||||
boolean autoStart = a.getBoolean(
|
||||
R.styleable.AnimatedImageDrawable_autoStart, false);
|
||||
if (autoStart && mState.mNativePtr != 0) {
|
||||
this.start();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user