Chromium Code Reviews| Index: chrome/browser/ui/fullscreen/fullscreen_controller.cc |
| diff --git a/chrome/browser/ui/fullscreen/fullscreen_controller.cc b/chrome/browser/ui/fullscreen/fullscreen_controller.cc |
| index 7c1621e0a32673e73d50ff51c71ef71a61af55d4..7fc8da75b87b3d97e7d38003e5a08726a5a97f4e 100644 |
| --- a/chrome/browser/ui/fullscreen/fullscreen_controller.cc |
| +++ b/chrome/browser/ui/fullscreen/fullscreen_controller.cc |
| @@ -28,6 +28,9 @@ |
| #if defined(OS_MACOSX) |
| #include "base/mac/mac_util.h" |
| +#else |
| +#include "base/prefs/pref_service.h" |
| +#include "chrome/common/pref_names.h" |
| #endif |
| using content::RenderViewHost; |
| @@ -552,6 +555,14 @@ void FullscreenController::ToggleFullscreenModeInternal( |
| if (chrome::IsRunningInAppMode() && window_->IsFullscreen()) |
| return; |
| +#if !defined(OS_MACOSX) |
| + // Do not enter fullscreen mode if disallowed by pref. |
|
scheib
2013/08/22 23:57:26
Have you tested this in combination with kiosk mod
bartfab (slow)
2013/08/23 11:54:21
Added documentation here, in pref_names.cc and pol
|
| + if (enter_fullscreen && |
| + !profile_->GetPrefs()->GetBoolean(prefs::kFullscreenAllowed)) { |
| + return; |
| + } |
| +#endif |
| + |
| if (enter_fullscreen) |
| EnterFullscreenModeInternal(option); |
| else |