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

Unified Diff: chrome/browser/content_setting_bubble_model.cc

Issue 6735042: Move favicon from TabContents to TabContentsWrapper. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 9 years, 9 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/content_setting_bubble_model.cc
diff --git a/chrome/browser/content_setting_bubble_model.cc b/chrome/browser/content_setting_bubble_model.cc
index d93f3798ab1963604069721971844caa00be0d93..66279cb81a23ee638128cea27f1c1183aff7c16b 100644
--- a/chrome/browser/content_setting_bubble_model.cc
+++ b/chrome/browser/content_setting_bubble_model.cc
@@ -8,12 +8,14 @@
#include "base/utf_string_conversions.h"
#include "chrome/browser/blocked_content_container.h"
#include "chrome/browser/content_settings/host_content_settings_map.h"
+#include "chrome/browser/favicon_tab_helper.h"
#include "chrome/browser/geolocation/geolocation_content_settings_map.h"
#include "chrome/browser/metrics/user_metrics.h"
#include "chrome/browser/prefs/pref_service.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/tab_contents/tab_specific_content_settings.h"
#include "chrome/browser/ui/collected_cookies_infobar_delegate.h"
+#include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h"
#include "chrome/common/pref_names.h"
#include "content/browser/renderer_host/render_view_host.h"
#include "content/browser/tab_contents/tab_contents.h"
@@ -384,6 +386,9 @@ class ContentSettingPopupBubbleModel : public ContentSettingSingleRadioGroup {
&blocked_contents);
for (std::vector<TabContents*>::const_iterator
i(blocked_contents.begin()); i != blocked_contents.end(); ++i) {
+ // TODO(avi): move blocked contents from TC to TCW; remove this.
+ TabContentsWrapper* wrapper =
+ TabContentsWrapper::GetCurrentWrapperForContents(*i);
std::string title(UTF16ToUTF8((*i)->GetTitle()));
// The popup may not have committed a load yet, in which case it won't
// have a URL or title.
@@ -391,7 +396,7 @@ class ContentSettingPopupBubbleModel : public ContentSettingSingleRadioGroup {
title = l10n_util::GetStringUTF8(IDS_TAB_LOADING_TITLE);
PopupItem popup_item;
popup_item.title = title;
- popup_item.bitmap = (*i)->GetFavicon();
+ popup_item.bitmap = wrapper->favicon_tab_helper()->GetFavicon();
popup_item.tab_contents = (*i);
add_popup(popup_item);
}
« no previous file with comments | « chrome/browser/chromeos/wm_overview_controller.cc ('k') | chrome/browser/extensions/extension_tabs_module.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698