Loading libs/WindowManager/Shell/src/com/android/wm/shell/compatui/letterbox/animations/LetterboxAnimationHandler.kt +18 −15 Original line number Diff line number Diff line Loading @@ -21,7 +21,6 @@ import android.animation.RectEvaluator import android.animation.ValueAnimator import android.graphics.Rect import android.os.IBinder import android.view.SurfaceControl import android.view.SurfaceControl.Transaction import android.window.TransitionInfo import android.window.TransitionRequestInfo Loading Loading @@ -104,7 +103,6 @@ class LetterboxAnimationHandler @Inject constructor( taskBounds, startBounds ) val leash: SurfaceControl = change.leash val tx: Transaction = transactionSupplier.get() animExecutor.execute { boundsAnimator?.cancel() Loading Loading @@ -137,8 +135,10 @@ class LetterboxAnimationHandler @Inject constructor( boundsAnimator?.addUpdateListener { animation -> val rect = animation.getAnimatedValue() as Rect for (c in info.changes) { tx.setPosition( leash, c.leash, rect.left.toFloat(), rect.top.toFloat() ).apply { Loading @@ -150,8 +150,11 @@ class LetterboxAnimationHandler @Inject constructor( ) }.apply() } } animExecutor.execute { tx.show(leash).apply() for (c in info.changes) { tx.show(c.leash).apply() } boundsAnimator?.start() } return true Loading services/core/java/com/android/server/wm/WindowOrganizerController.java +8 −2 Original line number Diff line number Diff line Loading @@ -1191,11 +1191,17 @@ class WindowOrganizerController extends IWindowOrganizerController.Stub if (currentTask != null) { final ActivityRecord top = currentTask.topRunningActivity(); if (top != null) { final ActivityRecord topOpaqueActivity = top.mAppCompatController .getTransparentPolicy().getFirstOpaqueActivity().orElse(top); if (chain.mTransition != null) { chain.mTransition.collect(top); // We also add the topOpaqueActivity if top is transparent. if (top != topOpaqueActivity) { chain.mTransition.collect(topOpaqueActivity); } top.mAppCompatController.getReachabilityPolicy().handleDoubleTap(doubleTapX, doubleTapY); } topOpaqueActivity.mAppCompatController.getReachabilityPolicy() .handleDoubleTap(doubleTapX, doubleTapY); } } effects |= TRANSACT_EFFECTS_CLIENT_CONFIG; Loading Loading
libs/WindowManager/Shell/src/com/android/wm/shell/compatui/letterbox/animations/LetterboxAnimationHandler.kt +18 −15 Original line number Diff line number Diff line Loading @@ -21,7 +21,6 @@ import android.animation.RectEvaluator import android.animation.ValueAnimator import android.graphics.Rect import android.os.IBinder import android.view.SurfaceControl import android.view.SurfaceControl.Transaction import android.window.TransitionInfo import android.window.TransitionRequestInfo Loading Loading @@ -104,7 +103,6 @@ class LetterboxAnimationHandler @Inject constructor( taskBounds, startBounds ) val leash: SurfaceControl = change.leash val tx: Transaction = transactionSupplier.get() animExecutor.execute { boundsAnimator?.cancel() Loading Loading @@ -137,8 +135,10 @@ class LetterboxAnimationHandler @Inject constructor( boundsAnimator?.addUpdateListener { animation -> val rect = animation.getAnimatedValue() as Rect for (c in info.changes) { tx.setPosition( leash, c.leash, rect.left.toFloat(), rect.top.toFloat() ).apply { Loading @@ -150,8 +150,11 @@ class LetterboxAnimationHandler @Inject constructor( ) }.apply() } } animExecutor.execute { tx.show(leash).apply() for (c in info.changes) { tx.show(c.leash).apply() } boundsAnimator?.start() } return true Loading
services/core/java/com/android/server/wm/WindowOrganizerController.java +8 −2 Original line number Diff line number Diff line Loading @@ -1191,11 +1191,17 @@ class WindowOrganizerController extends IWindowOrganizerController.Stub if (currentTask != null) { final ActivityRecord top = currentTask.topRunningActivity(); if (top != null) { final ActivityRecord topOpaqueActivity = top.mAppCompatController .getTransparentPolicy().getFirstOpaqueActivity().orElse(top); if (chain.mTransition != null) { chain.mTransition.collect(top); // We also add the topOpaqueActivity if top is transparent. if (top != topOpaqueActivity) { chain.mTransition.collect(topOpaqueActivity); } top.mAppCompatController.getReachabilityPolicy().handleDoubleTap(doubleTapX, doubleTapY); } topOpaqueActivity.mAppCompatController.getReachabilityPolicy() .handleDoubleTap(doubleTapX, doubleTapY); } } effects |= TRANSACT_EFFECTS_CLIENT_CONFIG; Loading