diff options
author | gab@chromium.org <gab@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-02-28 01:17:41 +0000 |
---|---|---|
committer | gab@chromium.org <gab@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-02-28 01:17:41 +0000 |
commit | c987a24655fedc08f1e04ee79e06e3f0df25d03a (patch) | |
tree | 5c1516372e1c2f6e8738c8168240c2784e2eb133 /chrome/browser/extensions/app_process_apitest.cc | |
parent | 160b8f609544fed63af64d1c24e4a70dda725e0d (diff) | |
download | chromium_src-c987a24655fedc08f1e04ee79e06e3f0df25d03a.zip chromium_src-c987a24655fedc08f1e04ee79e06e3f0df25d03a.tar.gz chromium_src-c987a24655fedc08f1e04ee79e06e3f0df25d03a.tar.bz2 |
Remove kDefaultHostDesktopType from browser_finder.cc.
This forces GetBrowserCount() and GetTabbedBrowserCount() to also take HostDesktopType; changed all consumers to provide desktop context in their query.
Introducing GetTotalBrowserCountForProfile() which is like GetBrowserCount(), but cummulative over all desktops; used in two scenarios where the caller of the old GetBrowserCount() actually wanted to know whether all browsers for a given profile were gone from the p.o.v. of the browser process (i.e. accross all desktops).
BUG=129187
Review URL: https://chromiumcodereview.appspot.com/12315094
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@185092 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/app_process_apitest.cc')
-rw-r--r-- | chrome/browser/extensions/app_process_apitest.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/chrome/browser/extensions/app_process_apitest.cc b/chrome/browser/extensions/app_process_apitest.cc index ceb75f6..759a46c 100644 --- a/chrome/browser/extensions/app_process_apitest.cc +++ b/chrome/browser/extensions/app_process_apitest.cc @@ -113,7 +113,8 @@ class AppApiTest : public ExtensionApiTest { // Opening tabs with window.open should keep the page in the opener's // process. - ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile())); + ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile(), + browser()->host_desktop_type())); OpenWindow(tab1, base_url.Resolve("path1/empty.html"), true, NULL); LOG(INFO) << "WindowOpenHelper 1."; OpenWindow(tab2, base_url.Resolve("path2/empty.html"), true, NULL); @@ -204,7 +205,8 @@ IN_PROC_BROWSER_TEST_F(AppApiTest, MAYBE_AppProcess) { GetRenderProcessHost()); // Now let's do the same using window.open. The same should happen. - ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile())); + ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile(), + browser()->host_desktop_type())); OpenWindow(tab, base_url.Resolve("path1/empty.html"), true, NULL); LOG(INFO) << "WindowOpenHelper 1."; OpenWindow(tab, base_url.Resolve("path2/empty.html"), true, NULL); @@ -329,7 +331,8 @@ IN_PROC_BROWSER_TEST_F(AppApiTest, BookmarkAppGetsNormalProcess) { GetRenderProcessHost()); // Now let's do the same using window.open. The same should happen. - ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile())); + ASSERT_EQ(1u, chrome::GetBrowserCount(browser()->profile(), + browser()->host_desktop_type())); OpenWindow(tab, base_url.Resolve("path1/empty.html"), true, NULL); OpenWindow(tab, base_url.Resolve("path2/empty.html"), true, NULL); |