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

Unified Diff: chrome/browser/plugins/chrome_content_browser_client_plugins_part.cc

Issue 2479593006: Move enable extensions define to a build flag. (Closed)
Patch Set: Merge Created 4 years, 1 month 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: chrome/browser/plugins/chrome_content_browser_client_plugins_part.cc
diff --git a/chrome/browser/plugins/chrome_content_browser_client_plugins_part.cc b/chrome/browser/plugins/chrome_content_browser_client_plugins_part.cc
index 70ffc9b28959e89ff434679bbe540e44e901af07..f9d68ce52941fd77fc8d38bd71fe96762aec13be 100644
--- a/chrome/browser/plugins/chrome_content_browser_client_plugins_part.cc
+++ b/chrome/browser/plugins/chrome_content_browser_client_plugins_part.cc
@@ -13,10 +13,11 @@
#include "chrome/common/pepper_permission_util.h"
#include "components/version_info/version_info.h"
#include "content/public/browser/render_process_host.h"
+#include "extensions/features/features.h"
#include "ppapi/host/ppapi_host.h"
#include "ppapi/shared_impl/ppapi_switches.h"
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/extension_service.h"
#include "extensions/browser/extension_registry.h"
#include "extensions/common/constants.h"
@@ -44,7 +45,7 @@ bool ChromeContentBrowserClientPluginsPart::
content::BrowserContext* browser_context,
const GURL& url,
const std::set<std::string>& allowed_file_handle_origins) {
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
Profile* profile = Profile::FromBrowserContext(browser_context);
const extensions::ExtensionSet* extension_set = NULL;
if (profile) {
@@ -67,7 +68,7 @@ bool ChromeContentBrowserClientPluginsPart::AllowPepperSocketAPI(
bool private_api,
const content::SocketPermissionRequest* params,
const std::set<std::string>& allowed_socket_origin) {
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
Profile* profile = Profile::FromBrowserContext(browser_context);
const extensions::ExtensionSet* extension_set = NULL;
if (profile) {
@@ -116,7 +117,7 @@ bool ChromeContentBrowserClientPluginsPart::AllowPepperSocketAPI(
bool ChromeContentBrowserClientPluginsPart::IsPepperVpnProviderAPIAllowed(
content::BrowserContext* browser_context,
const GURL& url) {
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
Profile* profile = Profile::FromBrowserContext(browser_context);
if (!profile)
return false;
@@ -151,7 +152,7 @@ bool ChromeContentBrowserClientPluginsPart::IsPluginAllowedToUseDevChannelAPIs(
return true;
}
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
Profile* profile = Profile::FromBrowserContext(browser_context);
const extensions::ExtensionSet* extension_set = NULL;
if (profile) {
« no previous file with comments | « chrome/browser/performance_monitor/performance_monitor.cc ('k') | chrome/browser/plugins/plugin_info_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698