Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(16)

Unified Diff: ui/views/cocoa/native_widget_mac_nswindow.mm

Issue 2069103004: MacViews: Attach child windows when parent is on the screen. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Disable test as potentialy flacky. Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/views/cocoa/bridged_native_widget.mm ('k') | ui/views/cocoa/views_nswindow_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/cocoa/native_widget_mac_nswindow.mm
diff --git a/ui/views/cocoa/native_widget_mac_nswindow.mm b/ui/views/cocoa/native_widget_mac_nswindow.mm
index 8c12aaa696bee1fc9b21cdf02a0bbb84d7145cd5..f3ccb522652a85af015b7bf64c9c3651ae8d91dd 100644
--- a/ui/views/cocoa/native_widget_mac_nswindow.mm
+++ b/ui/views/cocoa/native_widget_mac_nswindow.mm
@@ -129,26 +129,12 @@
[[self contentView] keyUp:event];
}
-// Override display, since this is the first opportunity Cocoa gives to detect
-// a visibility change in some cases. For example, restoring from the dock first
-// calls -[NSWindow display] before any NSWindowDelegate functions and before
-// ordering the window (and without actually calling -[NSWindow deminiaturize]).
-// By notifying the delegate that a display is about to occur, it can apply a
-// correct visibility state, before [super display] requests a draw of the
-// contentView. -[NSWindow isVisible] can still report NO at this point, so this
-// gives the delegate time to apply correct visibility before the draw occurs.
-- (void)display {
- [[self viewsNSWindowDelegate] onWindowWillDisplay];
- [super display];
-}
-
// Override window order functions to intercept other visibility changes. This
// is needed in addition to the -[NSWindow display] override because Cocoa
// hardly ever calls display, and reports -[NSWindow isVisible] incorrectly
// when ordering in a window for the first time.
- (void)orderWindow:(NSWindowOrderingMode)orderingMode
relativeTo:(NSInteger)otherWindowNumber {
- [[self viewsNSWindowDelegate] onWindowOrderWillChange:orderingMode];
[super orderWindow:orderingMode relativeTo:otherWindowNumber];
[[self viewsNSWindowDelegate] onWindowOrderChanged:nil];
}
« no previous file with comments | « ui/views/cocoa/bridged_native_widget.mm ('k') | ui/views/cocoa/views_nswindow_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698