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

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

Issue 659233002: STASH: Epic Experimental patch for toolkit-views App List on Mac Base URL: https://chromium.googlesource.com/chromium/src.git/+/master
Patch Set: Fix a few things. Works@master Created 6 years, 2 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/views_nswindow_delegate.h ('k') | ui/views/controls/webview/webview.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/cocoa/views_nswindow_delegate.mm
diff --git a/ui/views/cocoa/views_nswindow_delegate.mm b/ui/views/cocoa/views_nswindow_delegate.mm
index 038a844a2713d280b5673eb20d5e610a6c211d81..bfd80be116891799033f36265000ab02471a064d 100644
--- a/ui/views/cocoa/views_nswindow_delegate.mm
+++ b/ui/views/cocoa/views_nswindow_delegate.mm
@@ -11,6 +11,8 @@
@implementation ViewsNSWindowDelegate
+@synthesize transientChild = transientChild_;
+
- (id)initWithBridgedNativeWidget:(views::BridgedNativeWidget*)parent {
DCHECK(parent);
if ((self = [super init])) {
@@ -28,8 +30,9 @@
[parent_->ns_view() setWillShow:YES];
}
-- (void)onWindowOrderChanged {
+- (void)onWindowOrderChanged:(NSNotification*)notification {
[parent_->ns_view() setWillShow:NO];
+ parent_->OnVisibilityChanged();
}
// NSWindowDelegate implementation.
@@ -49,6 +52,14 @@
DCHECK(!parent_->target_fullscreen_state());
}
+- (void)windowDidResize:(NSNotification*)notification {
+ parent_->OnSizeChanged();
+}
+
+- (void)windowDidMove:(NSNotification*)notification {
+ parent_->native_widget_mac()->GetWidget()->OnNativeWidgetMove();
+}
+
- (void)windowDidBecomeKey:(NSNotification*)notification {
parent_->native_widget_mac()->GetWidget()->OnNativeWidgetActivationChanged(
true);
@@ -64,6 +75,14 @@
parent_->OnWindowWillClose();
}
+- (void)windowDidMiniaturize:(NSNotification*)notification {
+ parent_->OnVisibilityChanged();
+}
+
+- (void)windowDidDeminiaturize:(NSNotification*)notification {
+ parent_->OnVisibilityChanged();
+}
+
- (void)windowWillEnterFullScreen:(NSNotification*)notification {
parent_->OnFullscreenTransitionStart(true);
}
@@ -80,4 +99,28 @@
parent_->OnFullscreenTransitionComplete(false);
}
+- (void)windowDidChangeScreen:(NSNotification*)notification {
+ parent_->OnDisplayChanged();
+}
+
+- (void)windowDidChangeScreenProfile:(NSNotification*)notification {
+ parent_->OnDisplayChanged();
+}
+
+- (void)windowDidChangeBackingProperties:(NSNotification*)notification {
+ parent_->OnDisplayChanged();
+}
+
+- (void)windowWillStartLiveResize:(NSNotification*)notification {
+ parent_->native_widget_mac()
+ ->GetWidget()
+ ->OnNativeWidgetBeginUserBoundsChange();
+}
+
+- (void)windowDidEndLiveResize:(NSNotification*)notification {
+ parent_->native_widget_mac()
+ ->GetWidget()
+ ->OnNativeWidgetEndUserBoundsChange();
+}
+
@end
« no previous file with comments | « ui/views/cocoa/views_nswindow_delegate.h ('k') | ui/views/controls/webview/webview.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698