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

Unified Diff: ppapi/proxy/plugin_dispatcher.cc

Issue 8951014: Change the DidChangeView update to take a new ViewChanged resource. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: New patch Created 9 years 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
Index: ppapi/proxy/plugin_dispatcher.cc
diff --git a/ppapi/proxy/plugin_dispatcher.cc b/ppapi/proxy/plugin_dispatcher.cc
index 3da15e9bd3f93deaf6d66c0869e0260c1eebf4b8..43c620c958e37a17b6c3601c703bd2a053aaafe0 100644
--- a/ppapi/proxy/plugin_dispatcher.cc
+++ b/ppapi/proxy/plugin_dispatcher.cc
@@ -13,6 +13,7 @@
#include "ipc/ipc_sync_channel.h"
#include "base/debug/trace_event.h"
#include "ppapi/c/pp_errors.h"
+#include "ppapi/c/ppp_instance.h"
#include "ppapi/proxy/interface_list.h"
#include "ppapi/proxy/interface_proxy.h"
#include "ppapi/proxy/plugin_message_filter.h"
@@ -42,10 +43,8 @@ InstanceToDispatcherMap* g_instance_to_dispatcher = NULL;
} // namespace
InstanceData::InstanceData()
- : fullscreen(PP_FALSE),
- flash_fullscreen(PP_FALSE),
+ : flash_fullscreen(PP_FALSE),
mouse_lock_callback(PP_BlockUntilComplete()) {
- memset(&position, 0, sizeof(position));
}
InstanceData::~InstanceData() {
@@ -233,6 +232,14 @@ void PluginDispatcher::OnMsgSupportsInterface(
const std::string& interface_name,
bool* result) {
*result = !!GetPluginInterface(interface_name);
+
+ // Do fallback for PPP_Instance. This is a hack here and if we have more
+ // cases like this it should be generalized. The PPP_Instance proxy always
+ // prroxies the 1.1 interface, and then does fallback to 1.0 inside the
dmichael (off chromium) 2011/12/20 19:01:34 prroxies->proxies
+ // plugin process (see PPP_Instance_Proxy). So here we return true for
+ // supporting the 1.1 interface if either 1.1 or 1.0 is supported.
+ if (!*result && interface_name == PPP_INSTANCE_INTERFACE)
+ *result = !!GetPluginInterface(PPP_INSTANCE_INTERFACE_1_0);
}
void PluginDispatcher::OnMsgSetPreferences(const Preferences& prefs) {

Powered by Google App Engine
This is Rietveld 408576698