views: Account for transforms on a bubble's anchor widget.
In cros, normally overview related, we apply transforms on an anchor widget (normal the browser). The browser may have a number of transient bubbles associated with it. The transient bubbles get transformed to the correct locations on entry, but when the anchor widget's bounds update, we query the new transient bubbles bounds (and will transform). The transient bubbles bounds include the transform of their anchor, (GetAnchorBoundsInScreen()) applies transforms from descendants, so their offset by the anchor widget's translation. To counter this, undo the translation of the anchor widget when fetching the anchor rectangle. Easiest way to repro is by forcing the crash bubble to always show, then entering overview and rotating the chromebook. For a browser sized 1600x800 with anchor rect say 1500,0, after entering overview, the browser has a translation of 100,100. After rotating, the browser is sized 800x1600 and the anchor rect will be 800,100. On exiting the bubble correctly relocates and the anchor rect is seen to be 700,0. Test: manual Change-Id: Ie732e95e9b353cccfb7ae7158b6842596467d284 Fixed: 1004238, 1001039, 920134 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2305067 Commit-Queue: Sammie Quon <sammiequon@chromium.org> Reviewed-by:Allen Bauer <kylixrd@chromium.org> Cr-Commit-Position: refs/heads/master@{#790055}
Showing
Please register or sign in to comment