From 22fbd83872688074c9bdb5695749992cb8e0537d Mon Sep 17 00:00:00 2001 From: Mady Mellor Date: Wed, 4 Aug 2021 16:41:20 -0700 Subject: [PATCH] Fix touches activating TaskView when showing user education Test: manual - force user education to show, expand a bubble - while manage user education is up tap on the task view & verify the user education hides Bug: 195592791 Change-Id: Ie0e3647b8ea68ed8504b3ad7f27713ba15c5a8ca --- .../src/com/android/wm/shell/bubbles/ManageEducationView.kt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/ManageEducationView.kt b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/ManageEducationView.kt index de9970779b056..eb4737ac6c632 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/ManageEducationView.kt +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/ManageEducationView.kt @@ -47,6 +47,7 @@ class ManageEducationView constructor(context: Context, positioner: BubblePositi private var isHiding = false private var realManageButtonRect = Rect() + private var bubbleExpandedView: BubbleExpandedView? = null init { LayoutInflater.from(context).inflate(R.layout.bubbles_manage_button_education, this) @@ -97,6 +98,9 @@ class ManageEducationView constructor(context: Context, positioner: BubblePositi setButtonColor() if (visibility == VISIBLE) return + bubbleExpandedView = expandedView + expandedView.taskView?.setObscuredTouchRect(Rect(positioner.screenRect)) + layoutParams.width = if (positioner.isLargeScreen) context.resources.getDimensionPixelSize( R.dimen.bubbles_user_education_width_large_screen) @@ -131,6 +135,7 @@ class ManageEducationView constructor(context: Context, positioner: BubblePositi } fun hide() { + bubbleExpandedView?.taskView?.setObscuredTouchRect(null) if (visibility != VISIBLE || isHiding) return animate()