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

Side by Side Diff: chrome/browser/ui/cocoa/browser_window_controller.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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "chrome/browser/ui/cocoa/browser_window_controller.h" 5 #import "chrome/browser/ui/cocoa/browser_window_controller.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 #include <numeric> 8 #include <numeric>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 2133 matching lines...) Expand 10 before | Expand all | Expand 10 after
2144 2144
2145 - (BOOL)isInAnyFullscreenMode { 2145 - (BOOL)isInAnyFullscreenMode {
2146 return [self isInImmersiveFullscreen] || [self isInAppKitFullscreen]; 2146 return [self isInImmersiveFullscreen] || [self isInAppKitFullscreen];
2147 } 2147 }
2148 2148
2149 - (BOOL)isInImmersiveFullscreen { 2149 - (BOOL)isInImmersiveFullscreen {
2150 return fullscreenWindow_.get() != nil || enteringImmersiveFullscreen_; 2150 return fullscreenWindow_.get() != nil || enteringImmersiveFullscreen_;
2151 } 2151 }
2152 2152
2153 - (BOOL)isInAppKitFullscreen { 2153 - (BOOL)isInAppKitFullscreen {
2154 return ([[self window] styleMask] & NSFullScreenWindowMask) == 2154 return !exitingAppKitFullscreen_ &&
2155 NSFullScreenWindowMask || 2155 (([[self window] styleMask] & NSFullScreenWindowMask) ==
2156 enteringAppKitFullscreen_; 2156 NSFullScreenWindowMask ||
2157 enteringAppKitFullscreen_);
2157 } 2158 }
2158 2159
2159 - (void)enterExtensionFullscreenForURL:(const GURL&)url 2160 - (void)enterExtensionFullscreenForURL:(const GURL&)url
2160 bubbleType:(ExclusiveAccessBubbleType)bubbleType { 2161 bubbleType:(ExclusiveAccessBubbleType)bubbleType {
2161 if (chrome::mac::SupportsSystemFullscreen()) { 2162 if (chrome::mac::SupportsSystemFullscreen()) {
2162 fullscreenUrl_ = url; 2163 fullscreenUrl_ = url;
2163 exclusiveAccessBubbleType_ = bubbleType; 2164 exclusiveAccessBubbleType_ = bubbleType;
2164 [self enterBrowserFullscreenWithToolbar:NO]; 2165 [self enterBrowserFullscreenWithToolbar:NO];
2165 } else { 2166 } else {
2166 [self enterImmersiveFullscreen]; 2167 [self enterImmersiveFullscreen];
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
2266 2267
2267 - (BOOL)supportsBookmarkBar { 2268 - (BOOL)supportsBookmarkBar {
2268 return [self supportsWindowFeature:Browser::FEATURE_BOOKMARKBAR]; 2269 return [self supportsWindowFeature:Browser::FEATURE_BOOKMARKBAR];
2269 } 2270 }
2270 2271
2271 - (BOOL)isTabbedWindow { 2272 - (BOOL)isTabbedWindow {
2272 return browser_->is_type_tabbed(); 2273 return browser_->is_type_tabbed();
2273 } 2274 }
2274 2275
2275 @end // @implementation BrowserWindowController(WindowType) 2276 @end // @implementation BrowserWindowController(WindowType)
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_controller.h ('k') | chrome/browser/ui/cocoa/browser_window_controller_private.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698