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

Unified Diff: content/browser/plugin_service_impl.cc

Issue 11414180: Add a gyp flag to allow removing dependency on ppapi. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 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 | « content/browser/plugin_data_remover_impl.cc ('k') | content/browser/renderer_host/render_message_filter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/plugin_service_impl.cc
diff --git a/content/browser/plugin_service_impl.cc b/content/browser/plugin_service_impl.cc
index dabd26dfae7aedbaee98692c6f7ba9dca78dfc60..fa21c7d61491ed634706df8ba881793ef362d858 100644
--- a/content/browser/plugin_service_impl.cc
+++ b/content/browser/plugin_service_impl.cc
@@ -268,6 +268,7 @@ PpapiPluginProcessHost* PluginServiceImpl::FindOrStartPpapiPluginProcess(
const FilePath& plugin_path,
const FilePath& profile_data_directory,
PpapiPluginProcessHost::PluginClient* client) {
+#if defined(ENABLE_PLUGINS)
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
PpapiPluginProcessHost* plugin_host =
@@ -284,6 +285,9 @@ PpapiPluginProcessHost* PluginServiceImpl::FindOrStartPpapiPluginProcess(
return PpapiPluginProcessHost::CreatePluginHost(
*info, profile_data_directory,
client->GetResourceContext()->GetHostResolver());
+#else
+ return NULL;
+#endif
}
PpapiPluginProcessHost* PluginServiceImpl::FindOrStartPpapiBrokerProcess(
@@ -346,6 +350,7 @@ void PluginServiceImpl::OpenChannelToPpapiPlugin(
void PluginServiceImpl::OpenChannelToPpapiBroker(
const FilePath& path,
PpapiPluginProcessHost::BrokerClient* client) {
+#if defined(ENABLE_PLUGINS)
PpapiPluginProcessHost* plugin_host = FindOrStartPpapiBrokerProcess(path);
if (plugin_host) {
plugin_host->OpenChannelToPlugin(client);
@@ -353,6 +358,7 @@ void PluginServiceImpl::OpenChannelToPpapiBroker(
// Send error.
client->OnPpapiChannelOpened(IPC::ChannelHandle(), 0);
}
+#endif
}
void PluginServiceImpl::CancelOpenChannelToNpapiPlugin(
« no previous file with comments | « content/browser/plugin_data_remover_impl.cc ('k') | content/browser/renderer_host/render_message_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698