diff options
| author | 2021-05-07 01:51:36 +0000 | |
|---|---|---|
| committer | 2021-05-07 01:51:36 +0000 | |
| commit | edec7fd6b11feb857bf6c3216e9c64554bdbc644 (patch) | |
| tree | 2f1dbb4b15a5659fe0b042eda09f2f3d039a2708 | |
| parent | 4769fd369bb63ac0d9f42d10a96768e2c1d3870c (diff) | |
| parent | 679c4f7f67c24293ab9c201161bb58606859d532 (diff) | |
Merge "Immediately hide the icons when QS starts to expand" into sc-dev
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java | 43 |
1 files changed, 17 insertions, 26 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java b/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java index c69956f90c67..4a8ecc68a17b 100644 --- a/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java +++ b/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java @@ -242,35 +242,26 @@ public class QuickStatusBarHeader extends FrameLayout { .addFloat(mDateView, "alpha", 0, 1) .addFloat(mSecurityHeaderView, "alpha", 0, 1) .addFloat(mQSCarriers, "alpha", 0, 1); + builder.setListener(new TouchAnimator.ListenerAdapter() { + @Override + public void onAnimationAtEnd() { + mIconContainer.addIgnoredSlot(mMobileSlotName); + mIconContainer.addIgnoredSlot(mCallStrengthSlotName); + } - if (noCallingIcon != null || callStrengthIcon != null) { - if (noCallingIcon != null) { - builder.addFloat(noCallingIcon, "alpha", 1, 0); + @Override + public void onAnimationStarted() { + mIconContainer.addIgnoredSlot(mMobileSlotName); + mIconContainer.addIgnoredSlot(mCallStrengthSlotName); } - if (callStrengthIcon != null) { - builder.addFloat(callStrengthIcon, "alpha", 1, 0); + + @Override + public void onAnimationAtStart() { + super.onAnimationAtStart(); + mIconContainer.removeIgnoredSlot(mMobileSlotName); + mIconContainer.removeIgnoredSlot(mCallStrengthSlotName); } - builder.setListener(new TouchAnimator.ListenerAdapter() { - @Override - public void onAnimationAtEnd() { - mIconContainer.addIgnoredSlot(mMobileSlotName); - mIconContainer.addIgnoredSlot(mCallStrengthSlotName); - } - - @Override - public void onAnimationStarted() { - mIconContainer.removeIgnoredSlot(mMobileSlotName); - mIconContainer.removeIgnoredSlot(mCallStrengthSlotName); - } - - @Override - public void onAnimationAtStart() { - super.onAnimationAtStart(); - mIconContainer.removeIgnoredSlot(mMobileSlotName); - mIconContainer.removeIgnoredSlot(mCallStrengthSlotName); - } - }); - } + }); mAlphaAnimator = builder.build(); } |