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

Unified Diff: chrome/browser/ui/cocoa/full_size_content_window.mm

Issue 1276383004: Implemented fullscreen exit animation with AppKit (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed extra include Created 5 years, 4 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 | « chrome/browser/ui/cocoa/full_size_content_window.h ('k') | chrome/chrome_browser_ui.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/full_size_content_window.mm
diff --git a/chrome/browser/ui/cocoa/full_size_content_window.mm b/chrome/browser/ui/cocoa/full_size_content_window.mm
index 1dea52a7000bd65d1d62417433394e089eb08e28..04c76986226669f6222f2ff82c5be074ee75fd01 100644
--- a/chrome/browser/ui/cocoa/full_size_content_window.mm
+++ b/chrome/browser/ui/cocoa/full_size_content_window.mm
@@ -5,6 +5,7 @@
#import "chrome/browser/ui/cocoa/full_size_content_window.h"
#include "base/logging.h"
+#include "base/mac/foundation_util.h"
@interface FullSizeContentWindow ()
@@ -16,6 +17,11 @@
// as a NSWindow's contentView. It is needed because NSWindow's implementation
// explicitly resizes the contentView at inopportune times.
@interface FullSizeContentView : NSView
+
+// This method allows us to set the content view size since setFrameSize is
+// overridden to prevent the view from shrinking.
+- (void)forceFrameSize:(NSSize)size;
+
@end
@implementation FullSizeContentView
@@ -28,6 +34,10 @@
[super setFrameSize:size];
}
+- (void)forceFrameSize:(NSSize)size {
+ [super setFrameSize:size];
+}
+
@end
@implementation FullSizeContentWindow
@@ -81,6 +91,12 @@
return self;
}
+- (void)forceContentViewSize:(NSSize)size {
+ FullSizeContentView* contentView =
+ base::mac::ObjCCast<FullSizeContentView>(chromeWindowView_);
+ [contentView forceFrameSize:size];
+}
+
#pragma mark - Private Methods
+ (BOOL)shouldUseFullSizeContentViewForStyle:(NSUInteger)windowStyle {
« no previous file with comments | « chrome/browser/ui/cocoa/full_size_content_window.h ('k') | chrome/chrome_browser_ui.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698