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

Unified Diff: content/renderer/browser_plugin/browser_plugin_bindings.cc

Issue 284183013: Fix some webview plugin attach-ment code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: return value fix Created 6 years, 7 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/renderer/resources/extensions/web_view.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/browser_plugin/browser_plugin_bindings.cc
diff --git a/content/renderer/browser_plugin/browser_plugin_bindings.cc b/content/renderer/browser_plugin/browser_plugin_bindings.cc
index e78248fc513e4c826621950b38c3e871cce31f9d..624e19f88e5f65047960943516d472f3ece0ade7 100644
--- a/content/renderer/browser_plugin/browser_plugin_bindings.cc
+++ b/content/renderer/browser_plugin/browser_plugin_bindings.cc
@@ -236,6 +236,13 @@ class BrowserPluginBindingAttach: public BrowserPluginMethodBinding {
virtual bool Invoke(BrowserPluginBindings* bindings,
const NPVariant* args,
NPVariant* result) OVERRIDE {
+ bool attached = InvokeHelper(bindings, args);
+ BOOLEAN_TO_NPVARIANT(attached, *result);
+ return true;
+ }
+
+ private:
+ bool InvokeHelper(BrowserPluginBindings* bindings, const NPVariant* args) {
if (!bindings->instance()->render_view())
return false;
@@ -259,8 +266,6 @@ class BrowserPluginBindingAttach: public BrowserPluginMethodBinding {
bindings->instance()->Attach(instance_id, extra_params.Pass());
return true;
}
-
- private:
DISALLOW_COPY_AND_ASSIGN(BrowserPluginBindingAttach);
};
« no previous file with comments | « chrome/renderer/resources/extensions/web_view.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698