Merge "Fix AVD for CTS failure." into lmp-dev
This commit is contained in:
@@ -137,8 +137,7 @@ public class AnimatedVectorDrawable extends Drawable implements Animatable {
|
||||
private boolean mMutated;
|
||||
|
||||
public AnimatedVectorDrawable() {
|
||||
mAnimatedVectorState = new AnimatedVectorDrawableState(
|
||||
new AnimatedVectorDrawableState(null));
|
||||
mAnimatedVectorState = new AnimatedVectorDrawableState(null);
|
||||
}
|
||||
|
||||
private AnimatedVectorDrawable(AnimatedVectorDrawableState state, Resources res,
|
||||
@@ -160,9 +159,15 @@ public class AnimatedVectorDrawable extends Drawable implements Animatable {
|
||||
|
||||
@Override
|
||||
public ConstantState getConstantState() {
|
||||
mAnimatedVectorState.mChangingConfigurations = getChangingConfigurations();
|
||||
return mAnimatedVectorState;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getChangingConfigurations() {
|
||||
return super.getChangingConfigurations() | mAnimatedVectorState.mChangingConfigurations;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void draw(Canvas canvas) {
|
||||
mAnimatedVectorState.mVectorDrawable.draw(canvas);
|
||||
@@ -347,6 +352,8 @@ public class AnimatedVectorDrawable extends Drawable implements Animatable {
|
||||
mTargetNameMap.put(animClone, targetName);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
mVectorDrawable = new VectorDrawable();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user