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

Unified Diff: chrome/browser/policy/policy_browsertest.cc

Issue 22986010: Add policy for fullscreen mode; disallow fullscreen in public sessions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix browser test compilation after rebase. Created 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/policy/policy_browsertest.cc
diff --git a/chrome/browser/policy/policy_browsertest.cc b/chrome/browser/policy/policy_browsertest.cc
index cefed43da1b84a12983cc1ab23e6293de2d9083e..93c6043673156be95ef7fa3942b506c459fc92a7 100644
--- a/chrome/browser/policy/policy_browsertest.cc
+++ b/chrome/browser/policy/policy_browsertest.cc
@@ -1794,6 +1794,23 @@ IN_PROC_BROWSER_TEST_F(PolicyTest, FileURLBlacklist) {
CheckURLIsBlocked(browser(), file_path2.c_str());
}
+#if !defined(OS_MACOSX)
+IN_PROC_BROWSER_TEST_F(PolicyTest, FullscreenAllowed) {
+ PolicyMap policies;
+ policies.Set(key::kFullscreenAllowed,
+ POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER,
+ base::Value::CreateBooleanValue(false), NULL);
+ UpdateProviderPolicy(policies);
+
+ BrowserWindow* browser_window = browser()->window();
+ ASSERT_TRUE(browser_window);
+
+ EXPECT_FALSE(browser_window->IsFullscreen());
+ chrome::ToggleFullscreenMode(browser());
+ EXPECT_FALSE(browser_window->IsFullscreen());
+}
+#endif
+
#if defined(OS_CHROMEOS)
IN_PROC_BROWSER_TEST_F(PolicyTest, DisableScreenshotsFile) {
int screenshot_count = CountScreenshots();
« no previous file with comments | « chrome/browser/policy/configuration_policy_handler_list.cc ('k') | chrome/browser/ui/browser_command_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698