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

Unified Diff: chrome/browser/ui/cocoa/apps/quit_with_apps_controller_mac_interactive_uitest.cc

Issue 494033002: Move AppWindow to extensions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove unneeded include in chrome_shell_delegate.cc Created 6 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/ui/cocoa/apps/quit_with_apps_controller_mac_interactive_uitest.cc
diff --git a/chrome/browser/ui/cocoa/apps/quit_with_apps_controller_mac_interactive_uitest.cc b/chrome/browser/ui/cocoa/apps/quit_with_apps_controller_mac_interactive_uitest.cc
index 03ff030e4fdc3a61e9b39ed708bdba40255766d5..74a952bc2ba9d5991c56b1bd056079cbacacebf7 100644
--- a/chrome/browser/ui/cocoa/apps/quit_with_apps_controller_mac_interactive_uitest.cc
+++ b/chrome/browser/ui/cocoa/apps/quit_with_apps_controller_mac_interactive_uitest.cc
@@ -4,7 +4,6 @@
#include "chrome/browser/ui/cocoa/apps/quit_with_apps_controller_mac.h"
-#include "apps/app_window_registry.h"
#include "base/command_line.h"
#include "base/run_loop.h"
#include "chrome/browser/apps/app_browsertest_util.h"
@@ -21,11 +20,13 @@
#include "chrome/common/chrome_switches.h"
#include "content/public/browser/notification_service.h"
#include "content/public/test/test_utils.h"
+#include "extensions/browser/app_window/app_window_registry.h"
#include "extensions/browser/app_window/native_app_window.h"
#include "extensions/common/extension.h"
#include "ui/message_center/message_center.h"
-typedef apps::AppWindowRegistry::AppWindowList AppWindowList;
+using extensions::AppWindowRegistry;
+typedef AppWindowRegistry::AppWindowList AppWindowList;
namespace {
@@ -70,11 +71,11 @@ IN_PROC_BROWSER_TEST_F(QuitWithAppsControllerInteractiveTest, QuitBehavior) {
// One browser and one app window at this point.
EXPECT_FALSE(chrome::BrowserIterator().done());
- EXPECT_TRUE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_TRUE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
// On the first quit, show notification.
EXPECT_FALSE(controller->ShouldQuit());
- EXPECT_TRUE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_TRUE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
notification = g_browser_process->notification_ui_manager()->FindById(
QuitWithAppsController::kQuitWithAppsNotificationID);
ASSERT_TRUE(notification);
@@ -83,25 +84,25 @@ IN_PROC_BROWSER_TEST_F(QuitWithAppsControllerInteractiveTest, QuitBehavior) {
notification->delegate()->Click();
message_center->RemoveAllNotifications(false);
EXPECT_FALSE(controller->ShouldQuit());
- EXPECT_TRUE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_TRUE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
notification = g_browser_process->notification_ui_manager()->FindById(
QuitWithAppsController::kQuitWithAppsNotificationID);
ASSERT_TRUE(notification);
EXPECT_FALSE(chrome::BrowserIterator().done());
- EXPECT_TRUE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_TRUE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
// If notification is closed by user, don't show it next time.
notification->delegate()->Close(true);
message_center->RemoveAllNotifications(false);
EXPECT_FALSE(controller->ShouldQuit());
- EXPECT_TRUE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_TRUE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
notification = g_browser_process->notification_ui_manager()->FindById(
QuitWithAppsController::kQuitWithAppsNotificationID);
EXPECT_EQ(NULL, notification);
EXPECT_FALSE(chrome::BrowserIterator().done());
- EXPECT_TRUE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_TRUE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
// Quitting should not quit but close all browsers
content::WindowedNotificationObserver observer(
@@ -111,7 +112,7 @@ IN_PROC_BROWSER_TEST_F(QuitWithAppsControllerInteractiveTest, QuitBehavior) {
observer.Wait();
EXPECT_TRUE(chrome::BrowserIterator().done());
- EXPECT_TRUE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_TRUE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
// Trying to quit while there are no browsers always shows notification.
EXPECT_FALSE(controller->ShouldQuit());
@@ -126,6 +127,6 @@ IN_PROC_BROWSER_TEST_F(QuitWithAppsControllerInteractiveTest, QuitBehavior) {
content::NotificationService::AllSources());
notification->delegate()->ButtonClick(0);
message_center->RemoveAllNotifications(false);
- EXPECT_FALSE(apps::AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
+ EXPECT_FALSE(AppWindowRegistry::IsAppWindowRegisteredInAnyProfile(0));
quit_observer.Wait();
}

Powered by Google App Engine
This is Rietveld 408576698