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

Unified Diff: chrome/browser/ui/tabs/tab_strip_model.cc

Issue 10905301: Switch CoreTabHelper to use WebContentsUserData. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 3 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
« no previous file with comments | « chrome/browser/ui/tab_contents/tab_contents.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/tabs/tab_strip_model.cc
diff --git a/chrome/browser/ui/tabs/tab_strip_model.cc b/chrome/browser/ui/tabs/tab_strip_model.cc
index c622f87da28b953a5db28644bbfea2f0403e8e31..2c63cf8a8ec575109adfc6a865474344b97bfe44 100644
--- a/chrome/browser/ui/tabs/tab_strip_model.cc
+++ b/chrome/browser/ui/tabs/tab_strip_model.cc
@@ -756,8 +756,9 @@ bool TabStripModel::IsContextMenuCommandEnabled(
TabContents* tab = GetTabContentsAt(indices[i]);
if (tab) {
CoreTabHelperDelegate* core_delegate =
- tab->core_tab_helper()->delegate();
- if (!core_delegate || core_delegate->CanReloadContents(tab))
+ CoreTabHelper::FromWebContents(tab->web_contents())->delegate();
+ if (!core_delegate ||
+ core_delegate->CanReloadContents(tab->web_contents()))
return true;
}
}
@@ -822,8 +823,9 @@ void TabStripModel::ExecuteContextMenuCommand(
TabContents* tab = GetTabContentsAt(indices[i]);
if (tab) {
CoreTabHelperDelegate* core_delegate =
- tab->core_tab_helper()->delegate();
- if (!core_delegate || core_delegate->CanReloadContents(tab))
+ CoreTabHelper::FromWebContents(tab->web_contents())->delegate();
+ if (!core_delegate ||
+ core_delegate->CanReloadContents(tab->web_contents()))
tab->web_contents()->GetController().Reload(true);
}
}
« no previous file with comments | « chrome/browser/ui/tab_contents/tab_contents.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698