summaryrefslogtreecommitdiffstats
path: root/webkit
diff options
context:
space:
mode:
authorsatish@chromium.org <satish@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-20 15:49:51 +0000
committersatish@chromium.org <satish@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-20 15:49:51 +0000
commita026daa258eb0400aeb6357dd5ab3653cb182490 (patch)
tree76ed9b773d0719280a895948045a966fab48925d /webkit
parent53262643ac0804f941088db577a442c72bf6563a (diff)
downloadchromium_src-a026daa258eb0400aeb6357dd5ab3653cb182490.zip
chromium_src-a026daa258eb0400aeb6357dd5ab3653cb182490.tar.gz
chromium_src-a026daa258eb0400aeb6357dd5ab3653cb182490.tar.bz2
Wrap the p2p transport API in a compile time flag.
BUG=none TEST=none Review URL: http://codereview.chromium.org/6882021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82295 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit')
-rw-r--r--webkit/glue/webkit_glue.gypi8
-rw-r--r--webkit/plugins/ppapi/plugin_module.cc7
2 files changed, 11 insertions, 4 deletions
diff --git a/webkit/glue/webkit_glue.gypi b/webkit/glue/webkit_glue.gypi
index 1b5be84..475f2ec 100644
--- a/webkit/glue/webkit_glue.gypi
+++ b/webkit/glue/webkit_glue.gypi
@@ -285,8 +285,6 @@
'../plugins/ppapi/ppb_scrollbar_impl.h',
'../plugins/ppapi/ppb_surface_3d_impl.cc',
'../plugins/ppapi/ppb_surface_3d_impl.h',
- '../plugins/ppapi/ppb_transport_impl.cc',
- '../plugins/ppapi/ppb_transport_impl.h',
'../plugins/ppapi/ppb_url_loader_impl.cc',
'../plugins/ppapi/ppb_url_loader_impl.h',
'../plugins/ppapi/ppb_url_request_info_impl.cc',
@@ -504,6 +502,12 @@
'<(DEPTH)/webkit/support/setup_third_party.gyp:third_party_headers',
],
}],
+ ['p2p_apis==1', {
+ 'sources': [
+ '../plugins/ppapi/ppb_transport_impl.cc',
+ '../plugins/ppapi/ppb_transport_impl.h',
+ ],
+ }],
],
},
],
diff --git a/webkit/plugins/ppapi/plugin_module.cc b/webkit/plugins/ppapi/plugin_module.cc
index a7a7dd2..689d0b3 100644
--- a/webkit/plugins/ppapi/plugin_module.cc
+++ b/webkit/plugins/ppapi/plugin_module.cc
@@ -295,8 +295,6 @@ const void* GetInterface(const char* name) {
return PPB_Proxy_Impl::GetInterface();
if (strcmp(name, PPB_SCROLLBAR_DEV_INTERFACE) == 0)
return PPB_Scrollbar_Impl::GetInterface();
- if (strcmp(name, PPB_TRANSPORT_DEV_INTERFACE) == 0)
- return PPB_Transport_Impl::GetInterface();
if (strcmp(name, PPB_URLLOADER_INTERFACE) == 0)
return PPB_URLLoader_Impl::GetInterface();
if (strcmp(name, PPB_URLLOADERTRUSTED_INTERFACE) == 0)
@@ -341,6 +339,11 @@ const void* GetInterface(const char* name) {
return PPB_Flash_NetConnector_Impl::GetInterface();
#endif // ENABLE_FLAPPER_HACKS
+#if defined(ENABLE_P2P_APIS)
+ if (strcmp(name, PPB_TRANSPORT_DEV_INTERFACE) == 0)
+ return PPB_Transport_Impl::GetInterface();
+#endif
+
// Only support the testing interface when the command line switch is
// specified. This allows us to prevent people from (ab)using this interface
// in production code.