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

Unified Diff: chrome/browser/automation/testing_automation_provider.cc

Issue 8956050: Rename TabContents::controller() to GetController and put it into the WebContents interface. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years 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/automation/testing_automation_provider.cc
===================================================================
--- chrome/browser/automation/testing_automation_provider.cc (revision 115228)
+++ chrome/browser/automation/testing_automation_provider.cc (working copy)
@@ -533,7 +533,7 @@
browser->AddSelectedTabWithURL(url, content::PAGE_TRANSITION_TYPED);
if (contents) {
append_tab_response = GetIndexForNavigationController(
- &contents->tab_contents()->controller(), browser);
+ &contents->tab_contents()->GetController(), browser);
}
}
@@ -1250,7 +1250,7 @@
Browser* browser = browser_tracker_->GetResource(win_handle);
if (tab_index < browser->tab_count()) {
TabContents* tab_contents = browser->GetTabContentsAt(tab_index);
- *tab_handle = tab_tracker_->Add(&tab_contents->controller());
+ *tab_handle = tab_tracker_->Add(&tab_contents->GetController());
}
}
}
@@ -2961,7 +2961,7 @@
return;
}
scoped_ptr<DictionaryValue> return_value(new DictionaryValue);
- const NavigationController& controller = tab_contents->controller();
+ const NavigationController& controller = tab_contents->GetController();
NavigationEntry* nav_entry = controller.GetActiveEntry();
DCHECK(nav_entry);
@@ -3525,7 +3525,7 @@
DictionaryValue* args,
IPC::Message* reply_message) {
NavigationController& controller =
- browser->GetSelectedTabContents()->controller();
+ browser->GetSelectedTabContents()->GetController();
new OmniboxAcceptNotificationObserver(&controller, this, reply_message);
browser->window()->GetLocationBar()->AcceptInput();
}
@@ -4539,7 +4539,7 @@
if (!active || active->tab_contents() != tab ||
browser != BrowserList::GetLastActive()) {
browser->ActivateTabAt(
- browser->tabstrip_model()->GetIndexOfController(&tab->controller()),
+ browser->tabstrip_model()->GetIndexOfController(&tab->GetController()),
true /* user_gesture */);
}
}
@@ -5708,7 +5708,7 @@
// The key events will be sent to the browser window, we need the current tab
// containing the element we send the text in to be shown.
browser->ActivateTabAt(
- browser->GetIndexOfController(&tab_contents->controller()), true);
+ browser->GetIndexOfController(&tab_contents->GetController()), true);
BrowserWindow* browser_window = browser->window();
if (!browser_window) {
@@ -5841,7 +5841,7 @@
}
// This observer will delete itself.
- new AppLaunchObserver(&old_contents->controller(), this, reply_message,
+ new AppLaunchObserver(&old_contents->GetController(), this, reply_message,
launch_container);
Browser::OpenApplication(profile(), extension, launch_container, GURL(),
CURRENT_TAB);
@@ -6086,7 +6086,7 @@
return;
}
new NavigationNotificationObserver(
- &tab_contents->controller(), this, reply_message,
+ &tab_contents->GetController(), this, reply_message,
navigation_count, false, true);
browser->OpenURLFromTab(tab_contents, OpenURLParams(
GURL(url), content::Referrer(), CURRENT_TAB,
@@ -6174,7 +6174,7 @@
AutomationJSONReply(this, reply_message).SendError(error);
return;
}
- NavigationController& controller = tab_contents->controller();
+ NavigationController& controller = tab_contents->GetController();
if (!controller.CanGoForward()) {
DictionaryValue dict;
dict.SetBoolean("did_go_forward", false);
@@ -6198,7 +6198,7 @@
AutomationJSONReply(this, reply_message).SendError(error);
return;
}
- NavigationController& controller = tab_contents->controller();
+ NavigationController& controller = tab_contents->GetController();
if (!controller.CanGoBack()) {
DictionaryValue dict;
dict.SetBoolean("did_go_back", false);
@@ -6222,7 +6222,7 @@
AutomationJSONReply(this, reply_message).SendError(error);
return;
}
- NavigationController& controller = tab_contents->controller();
+ NavigationController& controller = tab_contents->GetController();
new NavigationNotificationObserver(&controller, this, reply_message,
1, false, true);
controller.Reload(false);
@@ -6408,7 +6408,7 @@
return;
}
browser->ActivateTabAt(
- browser->GetIndexOfController(&tab_contents->controller()), true);
+ browser->GetIndexOfController(&tab_contents->GetController()), true);
reply.SendSuccess(NULL);
}
« no previous file with comments | « chrome/browser/automation/automation_provider_win.cc ('k') | chrome/browser/background/background_contents_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698