OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/plugins/plugin_observer.h" | 5 #include "chrome/browser/plugins/plugin_observer.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 return BUTTON_OK; | 185 return BUTTON_OK; |
186 } | 186 } |
187 | 187 |
188 base::string16 ReloadPluginInfoBarDelegate::GetButtonLabel( | 188 base::string16 ReloadPluginInfoBarDelegate::GetButtonLabel( |
189 InfoBarButton button) const { | 189 InfoBarButton button) const { |
190 DCHECK_EQ(BUTTON_OK, button); | 190 DCHECK_EQ(BUTTON_OK, button); |
191 return l10n_util::GetStringUTF16(IDS_RELOAD_PAGE_WITH_PLUGIN); | 191 return l10n_util::GetStringUTF16(IDS_RELOAD_PAGE_WITH_PLUGIN); |
192 } | 192 } |
193 | 193 |
194 bool ReloadPluginInfoBarDelegate::Accept() { | 194 bool ReloadPluginInfoBarDelegate::Accept() { |
195 controller_->Reload(true); | 195 controller_->Reload(content::ReloadType::NORMAL, true); |
196 return true; | 196 return true; |
197 } | 197 } |
198 | 198 |
199 } // namespace | 199 } // namespace |
200 | 200 |
201 // PluginObserver ------------------------------------------------------------- | 201 // PluginObserver ------------------------------------------------------------- |
202 | 202 |
203 #if BUILDFLAG(ENABLE_PLUGIN_INSTALLATION) | 203 #if BUILDFLAG(ENABLE_PLUGIN_INSTALLATION) |
204 class PluginObserver::PluginPlaceholderHost : public PluginInstallerObserver { | 204 class PluginObserver::PluginPlaceholderHost : public PluginInstallerObserver { |
205 public: | 205 public: |
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
453 base::string16 plugin_name = | 453 base::string16 plugin_name = |
454 PluginService::GetInstance()->GetPluginDisplayNameByPath(plugin_path); | 454 PluginService::GetInstance()->GetPluginDisplayNameByPath(plugin_path); |
455 SimpleAlertInfoBarDelegate::Create( | 455 SimpleAlertInfoBarDelegate::Create( |
456 InfoBarService::FromWebContents(web_contents()), | 456 InfoBarService::FromWebContents(web_contents()), |
457 infobars::InfoBarDelegate::PLUGIN_OBSERVER, 0, | 457 infobars::InfoBarDelegate::PLUGIN_OBSERVER, 0, |
458 gfx::VectorIconId::EXTENSION_CRASHED, | 458 gfx::VectorIconId::EXTENSION_CRASHED, |
459 l10n_util::GetStringFUTF16(IDS_PLUGIN_INITIALIZATION_ERROR_PROMPT, | 459 l10n_util::GetStringFUTF16(IDS_PLUGIN_INITIALIZATION_ERROR_PROMPT, |
460 plugin_name), | 460 plugin_name), |
461 true); | 461 true); |
462 } | 462 } |
OLD | NEW |