commit | 337d25b2708fea6569eecd8067a00663b50741d3 | [log] [tgz] |
---|---|---|
author | TreeHugger Robot <treehugger-gerrit@google.com> | Tue Sep 07 19:03:48 2021 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Tue Sep 07 19:03:48 2021 +0000 |
tree | e7fb9e6695b4a5370287562867e6867ad4a16f1f | |
parent | 9cbab374c71e2125076fd052182182941bc10466 [diff] | |
parent | 99ce862e47a4d843be5e5cda8fe17e943fb8b8d6 [diff] |
Merge "Fix an issue with bubbles overlapping the taskbar" into sc-v2-dev am: 99ce862e47 Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15747691 Change-Id: I497b80f9757b26c6b3361a95b1111675545bc5b5
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java index 95b80df..9dafefe 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java
@@ -628,8 +628,11 @@ mAddedToWindowManager = true; mBubbleData.getOverflow().initialize(this); mWindowManager.addView(mStackView, mWmLayoutParams); - // Position info is dependent on us being attached to a window - mBubblePositioner.update(); + mStackView.setOnApplyWindowInsetsListener((view, windowInsets) -> { + mBubblePositioner.update(); + mStackView.onDisplaySizeChanged(); + return windowInsets; + }); } catch (IllegalStateException e) { // This means the stack has already been added. This shouldn't happen... e.printStackTrace();
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java index 5a51eed..5bc6128 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java
@@ -1315,6 +1315,7 @@ @Override protected void onAttachedToWindow() { super.onAttachedToWindow(); + mPositioner.update(); getViewTreeObserver().addOnComputeInternalInsetsListener(this); getViewTreeObserver().addOnDrawListener(mSystemGestureExcludeUpdater); }