diff options
author | Treehugger Robot <android-test-infra-autosubmit@system.gserviceaccount.com> | 2024-04-29 14:01:42 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2024-04-29 14:01:42 +0000 |
commit | e4596c37cbb7eb2242ce31b6bb73ebce906647fe (patch) | |
tree | f8a6869cc6d8cbdfdc77abfa6a5033768c7e0c6e | |
parent | 1cff81f46dcd05c86d7c13fc26892981c276aa68 (diff) | |
parent | 4995bb0e43d82cae6d8bf39c0b46e6c89df4bcd1 (diff) |
Merge "change the initialization order for adding overlays" into u-keystone-qcom-dev
-rw-r--r-- | packages/SystemUI/src/com/android/systemui/ScreenDecorations.java | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/ScreenDecorations.java b/packages/SystemUI/src/com/android/systemui/ScreenDecorations.java index 4dc227c91177..d3196f6c03e1 100644 --- a/packages/SystemUI/src/com/android/systemui/ScreenDecorations.java +++ b/packages/SystemUI/src/com/android/systemui/ScreenDecorations.java @@ -566,12 +566,8 @@ public class ScreenDecorations implements CoreStartable, Tunable , Dumpable { List<DecorProvider> decorProviders = getProviders(mHwcScreenDecorationSupport != null); removeRedundantOverlayViews(decorProviders); - if (mHwcScreenDecorationSupport != null) { - createHwcOverlay(); - } else { - removeHwcOverlay(); - } - + // Overlays are added in 2 steps: first the standard overlays. Then, if applicable, the + // HWC overlays. This ensures that the HWC overlays are always on top boolean[] hasCreatedOverlay = new boolean[BOUNDS_POSITION_LENGTH]; final boolean shouldOptimizeVisibility = shouldOptimizeVisibility(); Integer bound; @@ -588,6 +584,13 @@ public class ScreenDecorations implements CoreStartable, Tunable , Dumpable { } } + // Adding the HWC overlays second so they are on top by default + if (mHwcScreenDecorationSupport != null) { + createHwcOverlay(); + } else { + removeHwcOverlay(); + } + if (shouldOptimizeVisibility) { mDotViewController.setShowingListener(mPrivacyDotShowingListener); } else { |