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

Unified Diff: chrome/browser/plugins/plugin_observer.cc

Issue 2711623003: Update infobars to use VectorIcon struct instead of VectorIconId. (Closed)
Patch Set: rebase Created 3 years, 10 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/plugins/plugin_infobar_delegates.cc ('k') | chrome/browser/ui/chrome_select_file_policy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/plugins/plugin_observer.cc
diff --git a/chrome/browser/plugins/plugin_observer.cc b/chrome/browser/plugins/plugin_observer.cc
index 82c9555f5964aade2dc70f5ac2e1271a1264f612..48157a8cb9fb35742c34912df7c0a6e09475d8c1 100644
--- a/chrome/browser/plugins/plugin_observer.cc
+++ b/chrome/browser/plugins/plugin_observer.cc
@@ -13,6 +13,7 @@
#include "base/metrics/histogram_macros.h"
#include "base/strings/utf_string_conversions.h"
#include "build/build_config.h"
+#include "chrome/app/vector_icons/vector_icons.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/infobars/infobar_service.h"
#include "chrome/browser/lifetime/application_lifetime.h"
@@ -40,7 +41,6 @@
#include "content/public/browser/web_contents_delegate.h"
#include "content/public/common/webplugininfo.h"
#include "ui/base/l10n/l10n_util.h"
-#include "ui/gfx/vector_icons_public.h"
#if BUILDFLAG(ENABLE_PLUGIN_INSTALLATION)
#include "chrome/browser/plugins/plugin_installer.h"
@@ -136,7 +136,7 @@ class ReloadPluginInfoBarDelegate : public ConfirmInfoBarDelegate {
// ConfirmInfobarDelegate:
infobars::InfoBarDelegate::InfoBarIdentifier GetIdentifier() const override;
- gfx::VectorIconId GetVectorIconId() const override;
+ const gfx::VectorIcon& GetVectorIcon() const override;
base::string16 GetMessageText() const override;
int GetButtons() const override;
base::string16 GetButtonLabel(InfoBarButton button) const override;
@@ -169,8 +169,8 @@ ReloadPluginInfoBarDelegate::GetIdentifier() const {
return RELOAD_PLUGIN_INFOBAR_DELEGATE;
}
-gfx::VectorIconId ReloadPluginInfoBarDelegate::GetVectorIconId() const {
- return gfx::VectorIconId::EXTENSION_CRASHED;
+const gfx::VectorIcon& ReloadPluginInfoBarDelegate::GetVectorIcon() const {
+ return kExtensionCrashedIcon;
}
base::string16 ReloadPluginInfoBarDelegate::GetMessageText() const {
@@ -437,8 +437,7 @@ void PluginObserver::OnCouldNotLoadPlugin(const base::FilePath& plugin_path) {
PluginService::GetInstance()->GetPluginDisplayNameByPath(plugin_path);
SimpleAlertInfoBarDelegate::Create(
InfoBarService::FromWebContents(web_contents()),
- infobars::InfoBarDelegate::PLUGIN_OBSERVER, 0,
- gfx::VectorIconId::EXTENSION_CRASHED,
+ infobars::InfoBarDelegate::PLUGIN_OBSERVER, &kExtensionCrashedIcon,
l10n_util::GetStringFUTF16(IDS_PLUGIN_INITIALIZATION_ERROR_PROMPT,
plugin_name),
true);
« no previous file with comments | « chrome/browser/plugins/plugin_infobar_delegates.cc ('k') | chrome/browser/ui/chrome_select_file_policy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698