diff options
| author | 2022-08-23 15:39:08 +0900 | |
|---|---|---|
| committer | 2022-08-23 17:13:08 +0900 | |
| commit | bff5c972ac33121b606c8c2235d7be1d13acdb02 (patch) | |
| tree | 84fd0478b2354ae7cd212422aee24186f99838f9 | |
| parent | ff0cd826a23e58fb382e3e4372d52912e58afa07 (diff) | |
Replace region intersection change from quickReject to use Region#op
quickReject only checks outer bounds and not the invididual region
boundaries, this might give false negative (as the method doc suggests).
This caused a bug where window is still added to a11y window list
although it has been fully covered by a dialog (still intersects with
unaccountedSpace).
Bug: 240885392
Test: atest android.autofillservice.cts.servicebehavior.SettingsIntentTest
Change-Id: I7fc226e2288c2433e427d1e8ef173a3a21a20edc
| -rw-r--r-- | services/core/java/com/android/server/wm/AccessibilityController.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/wm/AccessibilityController.java b/services/core/java/com/android/server/wm/AccessibilityController.java index c04b19558770..4153ea5cb936 100644 --- a/services/core/java/com/android/server/wm/AccessibilityController.java +++ b/services/core/java/com/android/server/wm/AccessibilityController.java @@ -1655,7 +1655,8 @@ final class AccessibilityController { } // If the window is completely covered by other windows - ignore. - if (unaccountedSpace.quickReject(regionInScreen)) { + Region intersectionWindow = mTempRegion1; + if (!intersectionWindow.op(unaccountedSpace, regionInScreen, Region.Op.INTERSECT)) { return false; } |