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 7b7506dcdbaf2404a30b8ca5ff4d629b87d39e91..0aba7d85ad9c4aa83cc6d3b19d91b0ec3755dc57 100644 |
--- a/chrome/renderer/plugins/chrome_plugin_placeholder.cc |
+++ b/chrome/renderer/plugins/chrome_plugin_placeholder.cc |
@@ -35,8 +35,6 @@ using blink::WebNode; |
using blink::WebPlugin; |
using blink::WebPluginContainer; |
using blink::WebPluginParams; |
-using webkit_glue::CppArgumentList; |
-using webkit_glue::CppVariant; |
namespace { |
const plugins::PluginPlaceholder* g_last_active_menu = NULL; |
@@ -64,6 +62,7 @@ ChromePluginPlaceholder::ChromePluginPlaceholder( |
has_host_(false), |
context_menu_request_id_(0) { |
RenderThread::Get()->AddObserver(this); |
+ RegisterCallback("openAboutPlugins"); |
} |
ChromePluginPlaceholder::~ChromePluginPlaceholder() { |
@@ -217,13 +216,6 @@ void ChromePluginPlaceholder::OnLoadBlockedPlugins( |
plugins::PluginPlaceholder::OnLoadBlockedPlugins(identifier); |
} |
-void ChromePluginPlaceholder::OpenAboutPluginsCallback( |
- const CppArgumentList& args, |
- CppVariant* result) { |
- RenderThread::Get()->Send( |
- new ChromeViewHostMsg_OpenAboutPlugins(routing_id())); |
-} |
- |
void ChromePluginPlaceholder::OnSetIsPrerendering(bool is_prerendering) { |
plugins::PluginPlaceholder::OnSetIsPrerendering(is_prerendering); |
} |
@@ -352,9 +344,8 @@ void ChromePluginPlaceholder::ShowContextMenu(const WebMouseEvent& event) { |
g_last_active_menu = this; |
} |
-void ChromePluginPlaceholder::BindWebFrame(blink::WebFrame* frame) { |
- plugins::PluginPlaceholder::BindWebFrame(frame); |
- BindCallback("openAboutPlugins", |
- base::Bind(&ChromePluginPlaceholder::OpenAboutPluginsCallback, |
- base::Unretained(this))); |
+void ChromePluginPlaceholder::Observe(const std::string& callback) { |
+ DCHECK_EQ("openAboutPlugins", callback); |
+ RenderThread::Get()->Send( |
+ new ChromeViewHostMsg_OpenAboutPlugins(routing_id())); |
} |