From 2d5b0495316c5b37a1acb71446698f3896338210 Mon Sep 17 00:00:00 2001 From: Andy Wickham Date: Wed, 14 Sep 2022 15:50:40 -0700 Subject: [PATCH] Pivot search results scale around top of view. This way views scale in/out relative to the top of the view, instead of the center. This is most noticeable on larger views, like Search Edu card. Before/after videos: https://drive.google.com/drive/folders/1aXMGD44AQBeu6cLyzpV1DcFeh1Q8Vvmk?resourcekey=0-ShsGtgCTcST5cjUPAGPfwg&usp=sharing Bug: 234882587 Test: Manual with 10x animation duration. Change-Id: Ifb02f9dcb14e69b9cf3f9dea55d03d155b720391 --- .../android/launcher3/allapps/SearchTransitionController.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/com/android/launcher3/allapps/SearchTransitionController.java b/src/com/android/launcher3/allapps/SearchTransitionController.java index 03529af405..4be715ba19 100644 --- a/src/com/android/launcher3/allapps/SearchTransitionController.java +++ b/src/com/android/launcher3/allapps/SearchTransitionController.java @@ -233,6 +233,7 @@ public class SearchTransitionController { private void onSearchChildAttached(View child) { // Avoid allocating hardware layers for alpha changes. child.forceHasOverlappingRendering(false); + child.setPivotY(0); if (mSearchToAzProgress > 0) { // Before the child is rendered, apply the animation including it to avoid flicker. updateSearchRecyclerViewProgress();