Chromium Code Reviews| Index: chrome/browser/infobars/infobar_delegate.cc |
| diff --git a/chrome/browser/infobars/infobar_delegate.cc b/chrome/browser/infobars/infobar_delegate.cc |
| index 719b99fa6fa88b4616c75ffd2194d4c904b90bc8..6b6cfecade420eecc20b106d6fc1ed5573230952 100644 |
| --- a/chrome/browser/infobars/infobar_delegate.cc |
| +++ b/chrome/browser/infobars/infobar_delegate.cc |
| @@ -11,6 +11,7 @@ |
| #include "content/public/browser/navigation_details.h" |
| #include "content/public/browser/navigation_entry.h" |
| #include "content/public/browser/web_contents.h" |
| +#include "ui/base/resource/resource_bundle.h" |
| using content::NavigationEntry; |
| @@ -39,8 +40,17 @@ bool InfoBarDelegate::ShouldExpire( |
| void InfoBarDelegate::InfoBarDismissed() { |
| } |
| +int InfoBarDelegate::GetIconID() const { |
| + return -1; |
| +} |
| + |
| gfx::Image* InfoBarDelegate::GetIcon() const { |
| - return NULL; |
| + if (GetIconID() == -1) { |
| + return NULL; |
| + } else { |
|
Peter Kasting
2013/05/14 00:50:50
Nit: No else after return. Do this:
int icon_i
gone
2013/05/14 17:50:17
Done.
|
| + return &ResourceBundle::GetSharedInstance().GetNativeImageNamed( |
| + GetIconID()); |
| + } |
| } |
| InfoBarDelegate::Type InfoBarDelegate::GetInfoBarType() const { |