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

Unified Diff: chrome/browser/ui/hung_plugin_tab_helper.cc

Issue 15067008: [InfoBar] Add InfoBarDelegate::GetIconID() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nit fixes redux Created 7 years, 7 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/ui/hung_plugin_tab_helper.cc
diff --git a/chrome/browser/ui/hung_plugin_tab_helper.cc b/chrome/browser/ui/hung_plugin_tab_helper.cc
index eafc07212472b6a95643a671deb84edd9d448294..c656f63ea8690f02c11b12059de4037fe96d6fce 100644
--- a/chrome/browser/ui/hung_plugin_tab_helper.cc
+++ b/chrome/browser/ui/hung_plugin_tab_helper.cc
@@ -30,7 +30,6 @@
#include "grit/locale_settings.h"
#include "grit/theme_resources.h"
#include "ui/base/l10n/l10n_util.h"
-#include "ui/base/resource/resource_bundle.h"
#if defined(OS_WIN)
#include "base/win/scoped_handle.h"
@@ -148,7 +147,7 @@ class HungPluginInfoBarDelegate : public ConfirmInfoBarDelegate {
virtual ~HungPluginInfoBarDelegate();
// ConfirmInfoBarDelegate:
- virtual gfx::Image* GetIcon() const OVERRIDE;
+ virtual int GetIconID() const OVERRIDE;
virtual string16 GetMessageText() const OVERRIDE;
virtual int GetButtons() const OVERRIDE;
virtual string16 GetButtonLabel(InfoBarButton button) const OVERRIDE;
@@ -159,7 +158,6 @@ class HungPluginInfoBarDelegate : public ConfirmInfoBarDelegate {
string16 message_;
string16 button_text_;
- gfx::Image* icon_;
};
// static
@@ -185,15 +183,13 @@ HungPluginInfoBarDelegate::HungPluginInfoBarDelegate(
plugin_name);
button_text_ = l10n_util::GetStringUTF16(
IDS_BROWSER_HANGMONITOR_PLUGIN_INFOBAR_KILLBUTTON);
- icon_ = &ResourceBundle::GetSharedInstance().GetNativeImageNamed(
- IDR_INFOBAR_PLUGIN_CRASHED);
}
HungPluginInfoBarDelegate::~HungPluginInfoBarDelegate() {
}
-gfx::Image* HungPluginInfoBarDelegate::GetIcon() const {
- return icon_;
+int HungPluginInfoBarDelegate::GetIconID() const {
+ return IDR_INFOBAR_PLUGIN_CRASHED;
}
string16 HungPluginInfoBarDelegate::GetMessageText() const {
« no previous file with comments | « chrome/browser/ui/gtk/infobars/infobar_gtk.cc ('k') | chrome/browser/ui/omnibox/alternate_nav_infobar_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698