Chromium Code Reviews| Index: chrome/renderer/plugins/chrome_plugin_placeholder.cc |
| diff --git a/chrome/renderer/plugins/chrome_plugin_placeholder.cc b/chrome/renderer/plugins/chrome_plugin_placeholder.cc |
| index 7be06986d65254978cda28c61c026457d13787b6..af7a8811cfa52e67a64580e75532ed4da96834b8 100644 |
| --- a/chrome/renderer/plugins/chrome_plugin_placeholder.cc |
| +++ b/chrome/renderer/plugins/chrome_plugin_placeholder.cc |
| @@ -148,12 +148,14 @@ ChromePluginPlaceholder* ChromePluginPlaceholder::CreateBlockedPlugin( |
| content::RenderFrame* render_frame, |
| WebLocalFrame* frame, |
| const WebPluginParams& params, |
| - const content::WebPluginInfo& plugin, |
| + const content::WebPluginInfo& info, |
| const std::string& identifier, |
| const base::string16& name, |
| int template_id, |
| const base::string16& message, |
| - const GURL& poster_url) { |
| + const GURL& poster_url, |
| + blink::WebPlugin* premade_plugin, |
| + content::PluginInstanceThrottler* premade_throttler) { |
| base::DictionaryValue values; |
| values.SetString("message", message); |
| values.SetString("name", name); |
| @@ -177,7 +179,9 @@ ChromePluginPlaceholder* ChromePluginPlaceholder::CreateBlockedPlugin( |
| if (poster_url.is_valid()) |
| blocked_plugin->BlockForPowerSaverPoster(); |
| #endif |
| - blocked_plugin->SetPluginInfo(plugin); |
| + if (premade_plugin && premade_throttler) |
|
Lei Zhang
2015/01/30 21:50:07
Can the CreateBlockedPlugin() caller do this inste
tommycli
2015/02/02 18:35:47
Done.
|
| + blocked_plugin->SetPremadePlugin(premade_plugin, premade_throttler); |
| + blocked_plugin->SetPluginInfo(info); |
| blocked_plugin->SetIdentifier(identifier); |
| return blocked_plugin; |
| } |