From c91a43e110b96ad0e675f95e4d89cdae32262a74 Mon Sep 17 00:00:00 2001 From: Alex Chau Date: Wed, 3 Nov 2021 14:19:23 +0000 Subject: [PATCH] Revert "DO NOT MERGE Fix the cutout of magnification border" Revert "Do NOT MERGE Fix magnification border includes taskbar" Revert submission 16003793-magnification_border Bug: 196510717 Reason for revert: Caused NexusLauncherTests and NexusLauncherOutOfProcTests to stop running Reverted Changes: Ibbc9c51ea:Do NOT MERGE Fix magnification border includes tas... Ida2bb5bf1:DO NOT MERGE Fix the cutout of magnification borde... Change-Id: I6b2123aedd2a2f23142a34f158d2d9ab71948a18 --- .../taskbar/TaskbarActivityContext.java | 16 ---------------- .../taskbar/TaskbarDragLayerController.java | 4 ---- 2 files changed, 20 deletions(-) diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarActivityContext.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarActivityContext.java index ae647dbcaa..72d9d5b0b1 100644 --- a/quickstep/src/com/android/launcher3/taskbar/TaskbarActivityContext.java +++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarActivityContext.java @@ -510,20 +510,4 @@ public class TaskbarActivityContext extends ContextThemeWrapper implements Activ protected boolean isUserSetupComplete() { return mIsUserSetupComplete; } - - /** - * Called when we determine the touchable region. - * - * @param exclude {@code true} then the magnification region computation will omit the window. - */ - public void excludeFromMagnificationRegion(boolean exclude) { - if (exclude) { - mWindowLayoutParams.privateFlags |= - WindowManager.LayoutParams.PRIVATE_FLAG_EXCLUDE_FROM_SCREEN_MAGNIFICATION; - } else { - mWindowLayoutParams.privateFlags &= - ~WindowManager.LayoutParams.PRIVATE_FLAG_EXCLUDE_FROM_SCREEN_MAGNIFICATION; - } - mWindowManager.updateViewLayout(mDragLayer, mWindowLayoutParams); - } } diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarDragLayerController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarDragLayerController.java index 8c6185cb0f..cec892f7a7 100644 --- a/quickstep/src/com/android/launcher3/taskbar/TaskbarDragLayerController.java +++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarDragLayerController.java @@ -137,14 +137,12 @@ public class TaskbarDragLayerController { // Always have nav buttons be touchable mControllers.navbarButtonsViewController.addVisibleButtonsRegion( mTaskbarDragLayer, insetsInfo.touchableRegion); - boolean insetsIsTouchableRegion = true; if (mTaskbarDragLayer.getAlpha() < AlphaUpdateListener.ALPHA_CUTOFF_THRESHOLD) { // Let touches pass through us. insetsInfo.setTouchableInsets(TOUCHABLE_INSETS_REGION); } else if (mControllers.navbarButtonsViewController.isImeVisible()) { insetsInfo.setTouchableInsets(TOUCHABLE_INSETS_CONTENT); - insetsIsTouchableRegion = false; } else if (!mControllers.uiController.isTaskbarTouchable()) { // Let touches pass through us. insetsInfo.setTouchableInsets(TOUCHABLE_INSETS_REGION); @@ -153,11 +151,9 @@ public class TaskbarDragLayerController { // Taskbar has some touchable elements, take over the full taskbar area insetsInfo.setTouchableInsets(mActivity.isTaskbarWindowFullscreen() ? TOUCHABLE_INSETS_FRAME : TOUCHABLE_INSETS_CONTENT); - insetsIsTouchableRegion = false; } else { insetsInfo.setTouchableInsets(TOUCHABLE_INSETS_REGION); } - mActivity.excludeFromMagnificationRegion(insetsIsTouchableRegion); } /**