| 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 57a190c0e5488cad906db82462d371c3ca1e812b..9c2e44caec95387216fae9443df51c1b6bf20216 100644
|
| --- a/chrome/browser/ui/cocoa/browser_window_controller.mm
|
| +++ b/chrome/browser/ui/cocoa/browser_window_controller.mm
|
| @@ -80,6 +80,7 @@
|
| #include "chrome/browser/ui/window_sizer/window_sizer.h"
|
| #include "chrome/common/chrome_switches.h"
|
| #include "chrome/common/extensions/command.h"
|
| +#include "chrome/common/pref_names.h"
|
| #include "chrome/common/url_constants.h"
|
| #include "chrome/grit/generated_resources.h"
|
| #include "chrome/grit/locale_settings.h"
|
| @@ -432,6 +433,10 @@ void SetUpBrowserWindowCommandHandler(NSWindow* window) {
|
| extensions::ExtensionKeybindingRegistry::ALL_EXTENSIONS,
|
| windowShim_.get()));
|
|
|
| + PrefService* prefs = browser_->profile()->GetPrefs();
|
| + shouldHideFullscreenToolbar_ =
|
| + prefs->GetBoolean(prefs::kHideFullscreenToolbar);
|
| +
|
| blockLayoutSubviews_ = NO;
|
|
|
| // We are done initializing now.
|
| @@ -1918,6 +1923,10 @@ willAnimateFromState:(BookmarkBar::State)oldState
|
| [sheet orderOut:self];
|
| }
|
|
|
| +- (PresentationModeController*)presentationModeController {
|
| + return presentationModeController_.get();
|
| +}
|
| +
|
| - (void)executeExtensionCommand:(const std::string&)extension_id
|
| command:(const extensions::Command&)command {
|
| // Global commands are handled by the ExtensionCommandsGlobalRegistry
|
| @@ -1976,9 +1985,12 @@ willAnimateFromState:(BookmarkBar::State)oldState
|
| [self showFullscreenExitBubbleIfNecessary];
|
| }
|
|
|
| -- (void)toggleFullscreenToolbar {
|
| - shouldHideFullscreenToolbar_ = !shouldHideFullscreenToolbar_;
|
| +- (void)setFullscreenToolbarHidden:(BOOL)shouldHide {
|
| + if (shouldHideFullscreenToolbar_ == shouldHide)
|
| + return;
|
|
|
| + [presentationModeController_ setToolbarFraction:0.0];
|
| + shouldHideFullscreenToolbar_ = shouldHide;
|
| if ([self isInAppKitFullscreen])
|
| [self updateFullscreenWithToolbar:!shouldHideFullscreenToolbar_];
|
| }
|
|
|