DivestOS/Patches/LineageOS-15.1/android_frameworks_base/399770.patch
Tavi 3b0bc40f20
Churn + Fixes
Signed-off-by: Tavi <tavi@divested.dev>
2024-08-17 14:50:15 -04:00

34 lines
1.6 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Linus Tufvesson <lus@google.com>
Date: Mon, 29 Apr 2024 16:32:15 +0200
Subject: [PATCH] Hide SAW subwindows
.. when top window is hidden through Window#setHideOverlayWindows
Bug: 318683640
Test: atest CtsWindowManagerDeviceWindow:HideOverlayWindowsTest
Flag: EXEMPT securityfix
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:c37bc9147086f497ac7b1595083836014f524d5f)
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:89bc634cb534b8e0ffd798ac9f9f89ac1be0f785)
Merged-In: If19240f5aec2e048de80d75cbbdc00be47622d7f
Change-Id: If19240f5aec2e048de80d75cbbdc00be47622d7f
---
services/core/java/com/android/server/wm/WindowState.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/services/core/java/com/android/server/wm/WindowState.java b/services/core/java/com/android/server/wm/WindowState.java
index 77a8fec7241b..7eda006378b1 100644
--- a/services/core/java/com/android/server/wm/WindowState.java
+++ b/services/core/java/com/android/server/wm/WindowState.java
@@ -2558,8 +2558,9 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
}
void setForceHideNonSystemOverlayWindowIfNeeded(boolean forceHide) {
+ final int baseType = getBaseType();
if (mOwnerCanAddInternalSystemWindow
- || (!isSystemAlertWindowType(mAttrs.type) && mAttrs.type != TYPE_TOAST)) {
+ || (!isSystemAlertWindowType(baseType) && baseType != TYPE_TOAST)) {
return;
}
if (mForceHideNonSystemOverlayWindow == forceHide) {