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

Unified Diff: ppapi/proxy/dispatcher.cc

Issue 7189045: Make o.o.p. proxy handle PPP_Instance versions 0.4 and 0.5. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merged Created 9 years, 6 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 | « ppapi/proxy/dispatcher.h ('k') | ppapi/proxy/host_dispatcher.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/dispatcher.cc
diff --git a/ppapi/proxy/dispatcher.cc b/ppapi/proxy/dispatcher.cc
index 35a7d67e07b4e3cd58449acc410a3cd35cc9e8c1..3520752d9150eb9a8ca69fa194f6686c5f87ab36 100644
--- a/ppapi/proxy/dispatcher.cc
+++ b/ppapi/proxy/dispatcher.cc
@@ -103,12 +103,10 @@ struct InterfaceList {
// we're converting to the thunk system, when that is complete, we need to
// have a better way of handling multiple interface implemented by one
// proxy object.
- const InterfaceProxy::Info* id_to_plugin_info_[INTERFACE_ID_COUNT];
const InterfaceProxy::Info* id_to_browser_info_[INTERFACE_ID_COUNT];
};
InterfaceList::InterfaceList() {
- memset(id_to_plugin_info_, 0, sizeof(id_to_plugin_info_));
memset(id_to_browser_info_, 0, sizeof(id_to_browser_info_));
// PPB (browser) interfaces.
@@ -157,18 +155,16 @@ InterfaceList::InterfaceList() {
// PPP (plugin) interfaces.
AddPPP(PPP_Graphics3D_Proxy::GetInfo());
AddPPP(PPP_Instance_Private_Proxy::GetInfo());
- AddPPP(PPP_Instance_Proxy::GetInfo());
+ AddPPP(PPP_Instance_Proxy::GetInfo0_4());
+ AddPPP(PPP_Instance_Proxy::GetInfo0_5());
}
void InterfaceList::AddPPP(const InterfaceProxy::Info* info) {
DCHECK(name_to_plugin_info_.find(info->name) ==
name_to_plugin_info_.end());
DCHECK(info->id >= INTERFACE_ID_NONE && info->id < INTERFACE_ID_COUNT);
- DCHECK(info->id == INTERFACE_ID_NONE || id_to_plugin_info_[info->id] == NULL);
name_to_plugin_info_[info->name] = info;
- if (info->id != INTERFACE_ID_NONE)
- id_to_plugin_info_[info->id] = info;
}
void InterfaceList::AddPPB(const InterfaceProxy::Info* info) {
@@ -245,14 +241,6 @@ const InterfaceProxy::Info* Dispatcher::GetPPPInterfaceInfo(
return found->second;
}
-// static
-const InterfaceProxy::Info* Dispatcher::GetPPPInterfaceInfo(InterfaceID id) {
- if (id <= 0 || id >= INTERFACE_ID_COUNT)
- return NULL;
- const InterfaceList* list = InterfaceList::GetInstance();
- return list->id_to_plugin_info_[id];
-}
-
void Dispatcher::SetSerializationRules(
VarSerializationRules* var_serialization_rules) {
serialization_rules_.reset(var_serialization_rules);
« no previous file with comments | « ppapi/proxy/dispatcher.h ('k') | ppapi/proxy/host_dispatcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698