Chromium Code Reviews| Index: chrome/browser/ui/cocoa/browser_window_controller.mm |
| diff --git a/chrome/browser/ui/cocoa/browser_window_controller.mm b/chrome/browser/ui/cocoa/browser_window_controller.mm |
| index ca9e3b9d5731910b03a5c73914f93b473410f6b3..67acc08a906192fe788dd636bbc0ebaecd08e72e 100644 |
| --- a/chrome/browser/ui/cocoa/browser_window_controller.mm |
| +++ b/chrome/browser/ui/cocoa/browser_window_controller.mm |
| @@ -2107,11 +2107,11 @@ willAnimateFromState:(BookmarkBar::State)oldState |
| return presentationModeController_.get() != nil; |
| } |
| -- (void)enterPresentationModeForURL:(const GURL&)url |
| - bubbleType:(FullscreenExitBubbleType)bubbleType { |
| - DCHECK(chrome::mac::SupportsSystemFullscreen()); |
| - fullscreenUrl_ = url; |
| - fullscreenBubbleType_ = bubbleType; |
| +- (void)enterPresentationMode { |
| + if (!chrome::mac::SupportsSystemFullscreen()) { |
| + [self enterImmersiveFullscreen]; |
| + return; |
| + } |
| if ([self isInAppKitFullscreen]) { |
| // Already in AppKit Fullscreen. Adjust the UI to use Presentation Mode. |
| @@ -2125,8 +2125,21 @@ willAnimateFromState:(BookmarkBar::State)oldState |
| } |
| } |
| -- (void)enterHTML5FullscreenForURL:(const GURL&)url |
| - bubbleType:(FullscreenExitBubbleType)bubbleType { |
| +- (void)enterExtensionFullscreenForURL:(const GURL&)url |
|
erikchen
2014/09/15 23:55:37
I've intentionally separated out this logic from e
|
| + bubbleType:(FullscreenExitBubbleType)bubbleType { |
| + if (chrome::mac::SupportsSystemFullscreen()) { |
| + fullscreenUrl_ = url; |
| + fullscreenBubbleType_ = bubbleType; |
| + [self enterPresentationMode]; |
|
Robert Sesek
2014/09/16 15:49:02
Does this call -updateFullscreenExitBubble:?
erikchen
2014/09/16 17:12:36
The relevant method is -showFullscreenExitBubbleIf
|
| + } else { |
| + [self enterImmersiveFullscreen]; |
| + DCHECK(!url.is_empty()); |
| + [self updateFullscreenExitBubbleURL:url bubbleType:bubbleType]; |
| + } |
| +} |
| + |
| +- (void)enterWebContentFullscreenForURL:(const GURL&)url |
| + bubbleType:(FullscreenExitBubbleType)bubbleType { |
| [self enterImmersiveFullscreen]; |
| if (!url.is_empty()) |
| [self updateFullscreenExitBubbleURL:url bubbleType:bubbleType]; |