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

Unified Diff: ppapi/proxy/interface_list.cc

Issue 104673003: Pepper: Send dev/canary channel status to plugins. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: OVERRIDE build fix Created 7 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
« no previous file with comments | « ppapi/proxy/interface_list.h ('k') | ppapi/proxy/plugin_main_nacl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/interface_list.cc
diff --git a/ppapi/proxy/interface_list.cc b/ppapi/proxy/interface_list.cc
index 588d3545cdc13f691f52c42bcfb10301e75c98ba..8b05f7ace993144181dafb1f9a0df88f9b302b25 100644
--- a/ppapi/proxy/interface_list.cc
+++ b/ppapi/proxy/interface_list.cc
@@ -165,6 +165,7 @@ InterfaceProxy* ProxyFactory(Dispatcher* dispatcher) {
}
base::LazyInstance<PpapiPermissions> g_process_global_permissions;
+base::LazyInstance<bool> g_supports_dev_channel;
} // namespace
@@ -189,7 +190,6 @@ InterfaceList::InterfaceList() {
#include "ppapi/thunk/interfaces_ppb_private_no_permissions.h"
#include "ppapi/thunk/interfaces_ppb_public_stable.h"
}
-
{
Permission current_required_permission = PERMISSION_DEV;
#include "ppapi/thunk/interfaces_ppb_public_dev.h"
@@ -205,6 +205,8 @@ InterfaceList::InterfaceList() {
#endif // !defined(OS_NACL)
}
+ // TODO(teravest): Add dev channel interfaces here.
+
#undef PROXIED_API
#undef PROXIED_IFACE
@@ -310,6 +312,12 @@ void InterfaceList::SetProcessGlobalPermissions(
g_process_global_permissions.Get() = permissions;
}
+// static
+void InterfaceList::SetSupportsDevChannel(
+ bool supports_dev_channel) {
+ g_supports_dev_channel.Get() = supports_dev_channel;
+}
+
ApiID InterfaceList::GetIDForPPBInterface(const std::string& name) const {
NameToInterfaceInfoMap::const_iterator found =
name_to_browser_info_.find(name);
@@ -340,6 +348,8 @@ const void* InterfaceList::GetInterfaceForPPB(const std::string& name) const {
if (found == name_to_browser_info_.end())
return NULL;
+ // Dev channel checking goes here.
+
if (g_process_global_permissions.Get().HasPermission(
found->second.required_permission))
return found->second.iface;
« no previous file with comments | « ppapi/proxy/interface_list.h ('k') | ppapi/proxy/plugin_main_nacl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698