Chromium Code Reviews
DescriptionMacViews: Allow toolkit-views for "Global Error" bubbles.
The views dialogs will be chosen when run with the --secondary-ui-md
flag.
When the parent is a Cocoa browser window, an anchor point is chosen
rather than an anchor view, and the GlobalErrorBubbleView constructor is
updated to use this point when the anchor view is null.
The tricker part is that:
a) These dialogs are persistent (they do not dismiss when they lose
focus), and
b) The dialogs appear on the right side of the window,
This means they're more prone to "falling off" their anchor point when
resizing the browser window. For this, add a "BubbleAnchorHelper"
framework which is enabled by passing a visible toolkit-views bubble to
a KeepBubbleAnchored() function. The framework captures the anchor
position and ensures it is maintained when changes to the parent
NSWindow are observed.
Screenshot at http://crbug.com/675496#c1
BUG=675496
Review-Url: https://codereview.chromium.org/2586373003
Cr-Commit-Position: refs/heads/master@{#442503}
Committed: https://chromium.googlesource.com/chromium/src/+/84ce68dbf0aee72a6cfc16b3d50124078836d83c
Patch Set 1 : ViewsBubbleAnchorHelper #Patch Set 2 : neater #Patch Set 3 : workee #Patch Set 4 : a test \o/ #Patch Set 5 : rebase again #Patch Set 6 : unstage #
Total comments: 4
Patch Set 7 : addObserverForName #Messages
Total messages: 42 (32 generated)
|