From 33d3c266616ffdf0f56159d5cddd95ba5137ae9e Mon Sep 17 00:00:00 2001 From: Fabian Kozynski Date: Thu, 25 Aug 2022 14:36:17 -0400 Subject: [PATCH] Fix key frames in headers animation When setting values for `sizePercent` (or `percentX/Y`) in a KeyPosition, the value is the relative growth from 0 (beginning of animation) to 1 (end of animation). Therefore, in order to not have apparent size change (and movement) before and after the fade in the expansion, we need to set it to 0 for the `KeyPosition` before 0.5 and 1 for the one after. Test: manual, date and icons don't move horizontally on expansion Fixes: 243260726 Change-Id: I30fcb6f4f0a8f9cae98aba22c0400f9c5a8513f1 --- packages/SystemUI/res/xml/combined_qs_header_scene.xml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/SystemUI/res/xml/combined_qs_header_scene.xml b/packages/SystemUI/res/xml/combined_qs_header_scene.xml index 0fac76d11fbce..f3866c08cbfc6 100644 --- a/packages/SystemUI/res/xml/combined_qs_header_scene.xml +++ b/packages/SystemUI/res/xml/combined_qs_header_scene.xml @@ -29,17 +29,15 @@ app:percentX="0" app:percentY="0" app:framePosition="49" - app:percentWidth="1" - app:percentHeight="1" + app:sizePercent="0" app:curveFit="linear" app:motionTarget="@id/date" />