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

Unified Diff: chrome/browser/extensions/plugin_apitest.cc

Issue 10702029: Move tab functions off Browser into browser_tabstrip and browser_tabrestore. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 6 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/extensions/plugin_apitest.cc
===================================================================
--- chrome/browser/extensions/plugin_apitest.cc (revision 145001)
+++ chrome/browser/extensions/plugin_apitest.cc (working copy)
@@ -8,6 +8,7 @@
#include "chrome/browser/prefs/pref_service.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_commands.h"
+#include "chrome/browser/ui/browser_tabstrip.h"
#include "chrome/browser/ui/tab_contents/tab_contents.h"
#include "chrome/common/extensions/extension.h"
#include "chrome/common/pref_names.h"
@@ -38,7 +39,7 @@
ui_test_utils::NavigateToURL(browser(),
net::FilePathToFileURL(extension_dir.AppendASCII("test.html")));
- WebContents* tab = browser()->GetActiveWebContents();
+ WebContents* tab = chrome::GetActiveWebContents(browser());
// With no extensions, the plugin should not be loaded.
bool result = false;
@@ -80,7 +81,7 @@
ui_test_utils::WindowedNotificationObserver observer(
content::NOTIFICATION_LOAD_STOP,
content::Source<NavigationController>(
- &browser()->GetActiveWebContents()->GetController()));
+ &chrome::GetActiveWebContents(browser())->GetController()));
chrome::Reload(browser(), CURRENT_TAB);
observer.Wait();
}
@@ -112,7 +113,7 @@
// Load the test page through the extension URL, and the plugin should work.
ui_test_utils::NavigateToURL(browser(),
extension->GetResourceURL("test.html"));
- WebContents* tab = browser()->GetActiveWebContents();
+ WebContents* tab = chrome::GetActiveWebContents(browser());
bool result = false;
ASSERT_TRUE(ui_test_utils::ExecuteJavaScriptAndExtractBool(
tab->GetRenderViewHost(), L"", L"testPluginWorks()", &result));
« no previous file with comments | « chrome/browser/extensions/platform_app_browsertest.cc ('k') | chrome/browser/extensions/process_management_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698