OSDN Git Service

Restrict the space bubbles are centered in while in landscape
authorMady Mellor <madym@google.com>
Thu, 22 Aug 2019 00:25:02 +0000 (17:25 -0700)
committerMady Mellor <madym@google.com>
Wed, 18 Sep 2019 00:57:26 +0000 (17:57 -0700)
commite19353d67bcc958a73aa5a5e49d0db4b59c40892
tree6853e061db25fdc0331624e1350b58a1ef75c099
parentfd48588768726c067a40cc642a0eb29ac2e64f3d
Restrict the space bubbles are centered in while in landscape

In landscape don't use the full screen width, instead, restrict to a
percentage of the screen & enforce a minimum of the width of the screen.

* Updates the displaySize passed to ExpandedAnimationController
  to be the "real size", this is consistent with what BubbleExpandedView
  uses now
* Alters positioning calculations in ExpandedAnimationController &
  accounts for notches / screen decorations

Test: manual - have multiple bubbles
             - expand the stack
             - rotate the device
             => observe that the bubbles look nicely centered (i.e. not
                too much space or too little space) in landscape & portrait
Bug: 135487618
Change-Id: Ief7fc6f762f8cc130e37963d48005f15a1bea743
packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java
packages/SystemUI/src/com/android/systemui/bubbles/animation/ExpandedAnimationController.java