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

Side by Side Diff: chrome/browser/ui/fullscreen/fullscreen_controller_interactive_browsertest.cc

Issue 158253002: Tabs being screen-captured will fullscreen within their tab contents area. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed scheib's review comments. Rebased. Created 6 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "build/build_config.h" 5 #include "build/build_config.h"
6 #include "chrome/browser/content_settings/host_content_settings_map.h" 6 #include "chrome/browser/content_settings/host_content_settings_map.h"
7 #include "chrome/browser/fullscreen.h" 7 #include "chrome/browser/fullscreen.h"
8 #include "chrome/browser/profiles/profile.h" 8 #include "chrome/browser/profiles/profile.h"
9 #include "chrome/browser/ui/browser.h" 9 #include "chrome/browser/ui/browser.h"
10 #include "chrome/browser/ui/browser_commands.h" 10 #include "chrome/browser/ui/browser_commands.h"
(...skipping 630 matching lines...) Expand 10 before | Expand all | Expand 10 after
641 641
642 // Request to lock the mouse and enter fullscreen. 642 // Request to lock the mouse and enter fullscreen.
643 FullscreenNotificationObserver fullscreen_observer; 643 FullscreenNotificationObserver fullscreen_observer;
644 ASSERT_TRUE(ui_test_utils::SendKeyPressAndWait( 644 ASSERT_TRUE(ui_test_utils::SendKeyPressAndWait(
645 browser(), ui::VKEY_B, false, true, false, false, 645 browser(), ui::VKEY_B, false, true, false, false,
646 chrome::NOTIFICATION_MOUSE_LOCK_CHANGED, 646 chrome::NOTIFICATION_MOUSE_LOCK_CHANGED,
647 content::NotificationService::AllSources())); 647 content::NotificationService::AllSources()));
648 fullscreen_observer.Wait(); 648 fullscreen_observer.Wait();
649 649
650 // Confirm they are enabled and there is no prompt. 650 // Confirm they are enabled and there is no prompt.
651 ASSERT_TRUE(IsFullscreenBubbleDisplayed()); 651 ASSERT_FALSE(IsFullscreenBubbleDisplayed());
miu 2014/02/12 08:25:20 This test, that I originally authored, was broken
652 ASSERT_FALSE(IsFullscreenPermissionRequested()); 652 ASSERT_FALSE(IsFullscreenPermissionRequested());
653 ASSERT_FALSE(IsMouseLockPermissionRequested()); 653 ASSERT_FALSE(IsMouseLockPermissionRequested());
654 ASSERT_TRUE(IsMouseLocked()); 654 ASSERT_TRUE(IsMouseLocked());
655 ASSERT_TRUE(IsFullscreenForTabOrPending()); 655 ASSERT_TRUE(IsFullscreenForTabOrPending());
656 } 656 }
657 657
658 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) && defined(USE_AURA) 658 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) && defined(USE_AURA)
659 // TODO(erg): linux_aura bringup: http://crbug.com/163931 659 // TODO(erg): linux_aura bringup: http://crbug.com/163931
660 #define MAYBE_MouseLockSilentAfterTargetUnlock \ 660 #define MAYBE_MouseLockSilentAfterTargetUnlock \
661 DISABLED_MouseLockSilentAfterTargetUnlock 661 DISABLED_MouseLockSilentAfterTargetUnlock
(...skipping 262 matching lines...) Expand 10 before | Expand all | Expand 10 after
924 924
925 GURL url = test_server()->GetURL("simple.html"); 925 GURL url = test_server()->GetURL("simple.html");
926 AddTabAtIndex(0, url, PAGE_TRANSITION_TYPED); 926 AddTabAtIndex(0, url, PAGE_TRANSITION_TYPED);
927 927
928 // Validate that going fullscreen for a URL defaults to asking permision. 928 // Validate that going fullscreen for a URL defaults to asking permision.
929 ASSERT_FALSE(IsFullscreenPermissionRequested()); 929 ASSERT_FALSE(IsFullscreenPermissionRequested());
930 ASSERT_NO_FATAL_FAILURE(ToggleTabFullscreenNoRetries(true)); 930 ASSERT_NO_FATAL_FAILURE(ToggleTabFullscreenNoRetries(true));
931 ASSERT_TRUE(IsFullscreenPermissionRequested()); 931 ASSERT_TRUE(IsFullscreenPermissionRequested());
932 ASSERT_NO_FATAL_FAILURE(ToggleTabFullscreenNoRetries(false)); 932 ASSERT_NO_FATAL_FAILURE(ToggleTabFullscreenNoRetries(false));
933 } 933 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698