Fix initial alpha when unstashing bubble bar
For the stash and unstash animation we use separate timings for the
Bubble views and background. In other animations we animate the entire
bubble bar alpha as one.
To achieve this during unstash animation we set the bubble views and
background alpha to 0. And then set the bar alpha to 1.
Since alpha animation has a delay during unstash, we need to set the
initial values as the start of the entire animation and not just the
alpha part. Otherwise there are flickers in the animation.
We also need to set initial values for the alpha animator that the
AnimatedFloat creates. AnimatedFloat uses the current values as the
start value. If we update it later, the animator was already created and
it won't have an effect. To fix this, we set the start and end values
for the alpha animators created by AnimatedFloat.
Bug: 345488489
Flag: com.android.wm.shell.enable_bubble_bar
Test: slow down animations and unstash bubble bar, check that bubbles
alpha slowly animates in
Change-Id: I3cfdb715e1703bd2195c809fd77751a216558176
2 files changed