Align bubble bar stash anim with taskbar (1/n)
Only scale bubble bar background during stash and unstash animation. Follows the logic used for taskbar. We scale only the background and clip the icons separately. Bug: 345488489 Test: PersistentBubbleStashControllerTest Test: TransientBubbleStashControllerTest Test: BubbleBarViewAnimatorTest Test: stash and unstash bubble bar in app by swiping up from taskbar Test: expand and collapse bubble bar in app by swiping up on bar Test: expand and collapse bubble bar on home screen by tapping on it Flag: com.android.wm.shell.enable_bubble_bar Change-Id: Ifc7922c444f2179fc49643424815e5e7dde519cc
This commit is contained in:
@@ -82,6 +82,10 @@ public class BubbleBarViewController {
|
||||
private final MultiValueAlpha mBubbleBarAlpha;
|
||||
private final AnimatedFloat mBubbleBarScaleX = new AnimatedFloat(this::updateScaleX);
|
||||
private final AnimatedFloat mBubbleBarScaleY = new AnimatedFloat(this::updateScaleY);
|
||||
private final AnimatedFloat mBubbleBarBackgroundScaleX = new AnimatedFloat(
|
||||
this::updateBackgroundScaleX);
|
||||
private final AnimatedFloat mBubbleBarBackgroundScaleY = new AnimatedFloat(
|
||||
this::updateBackgroundScaleY);
|
||||
private final AnimatedFloat mBubbleBarTranslationY = new AnimatedFloat(
|
||||
this::updateTranslationY);
|
||||
|
||||
@@ -266,6 +270,14 @@ public class BubbleBarViewController {
|
||||
return mBubbleBarScaleY;
|
||||
}
|
||||
|
||||
public AnimatedFloat getBubbleBarBackgroundScaleX() {
|
||||
return mBubbleBarBackgroundScaleX;
|
||||
}
|
||||
|
||||
public AnimatedFloat getBubbleBarBackgroundScaleY() {
|
||||
return mBubbleBarBackgroundScaleY;
|
||||
}
|
||||
|
||||
public AnimatedFloat getBubbleBarTranslationY() {
|
||||
return mBubbleBarTranslationY;
|
||||
}
|
||||
@@ -535,6 +547,14 @@ public class BubbleBarViewController {
|
||||
mBarView.setScaleY(scale);
|
||||
}
|
||||
|
||||
private void updateBackgroundScaleX(float scale) {
|
||||
mBarView.setBackgroundScaleX(scale);
|
||||
}
|
||||
|
||||
private void updateBackgroundScaleY(float scale) {
|
||||
mBarView.setBackgroundScaleY(scale);
|
||||
}
|
||||
|
||||
//
|
||||
// Manipulating the specific bubble views in the bar
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user