| 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 7575a48e6256b8e21c0d184bb4aa963b62e420a0..e6616ac621bc604468998f4b4b2f16716dea9dd5 100644
|
| --- a/chrome/browser/ui/cocoa/browser_window_controller.mm
|
| +++ b/chrome/browser/ui/cocoa/browser_window_controller.mm
|
| @@ -81,6 +81,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"
|
| @@ -435,6 +436,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.
|
| @@ -1916,6 +1921,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
|
| @@ -1971,9 +1980,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_];
|
| }
|
|
|