Merge "Updated how taskbar touch area is being set." into main
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarInsetsController.kt b/quickstep/src/com/android/launcher3/taskbar/TaskbarInsetsController.kt
index 4c5564e..67cb7cb 100644
--- a/quickstep/src/com/android/launcher3/taskbar/TaskbarInsetsController.kt
+++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarInsetsController.kt
@@ -137,37 +137,23 @@
             }
         val touchableHeight = max(taskbarTouchableHeight, bubblesTouchableHeight)
 
-        if (
+        defaultTouchableRegion.set(
+            0,
+            windowLayoutParams.height - touchableHeight,
+            context.deviceProfile.widthPx,
+            windowLayoutParams.height
+        )
+        val isBubbleBarVisible =
             controllers.bubbleControllers.isPresent &&
                 controllers.bubbleControllers.get().bubbleStashController.isBubbleBarVisible()
-        ) {
+        // if there's an animating bubble add it to the touch region so that it's clickable
+        val isAnimatingNewBubble =
+            controllers.bubbleControllers.getOrNull()?.bubbleBarViewController?.isAnimatingNewBubble
+                ?: false
+        if (isBubbleBarVisible || isAnimatingNewBubble) {
             val iconBounds =
                 controllers.bubbleControllers.get().bubbleBarViewController.bubbleBarBounds
-            defaultTouchableRegion.set(
-                iconBounds.left,
-                iconBounds.top,
-                iconBounds.right,
-                iconBounds.bottom
-            )
-        } else {
-            defaultTouchableRegion.set(
-                0,
-                windowLayoutParams.height - touchableHeight,
-                context.deviceProfile.widthPx,
-                windowLayoutParams.height
-            )
-
-            // if there's an animating bubble add it to the touch region so that it's clickable
-            val isAnimatingNewBubble =
-                controllers.bubbleControllers
-                    .getOrNull()
-                    ?.bubbleBarViewController
-                    ?.isAnimatingNewBubble ?: false
-            if (isAnimatingNewBubble) {
-                val iconBounds =
-                    controllers.bubbleControllers.get().bubbleBarViewController.bubbleBarBounds
-                defaultTouchableRegion.op(iconBounds, Region.Op.UNION)
-            }
+            defaultTouchableRegion.op(iconBounds, Region.Op.UNION)
         }
 
         // Pre-calculate insets for different providers across different rotations for this gravity