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

Unified Diff: chrome/common/chrome_content_client.cc

Issue 2576573002: Move enable_pdf to a buildflag header. (Closed)
Patch Set: No Chromecast Created 4 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 | « chrome/common/BUILD.gn ('k') | chrome/test/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/chrome_content_client.cc
diff --git a/chrome/common/chrome_content_client.cc b/chrome/common/chrome_content_client.cc
index 20ba8876bd79e7d9d3672156011d40499d53f9f0..8d3124cf3e60287ff9e7d1786ce0d3993b30fda6 100644
--- a/chrome/common/chrome_content_client.cc
+++ b/chrome/common/chrome_content_client.cc
@@ -44,6 +44,7 @@
#include "extensions/features/features.h"
#include "gpu/config/gpu_info.h"
#include "net/http/http_util.h"
+#include "pdf/features.h"
#include "ppapi/features/features.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/base/layout.h"
@@ -90,14 +91,14 @@
namespace {
#if BUILDFLAG(ENABLE_PLUGINS)
-#if defined(ENABLE_PDF)
+#if BUILDFLAG(ENABLE_PDF)
const char kPDFPluginExtension[] = "pdf";
const char kPDFPluginDescription[] = "Portable Document Format";
const char kPDFPluginOutOfProcessMimeType[] =
"application/x-google-chrome-pdf";
const uint32_t kPDFPluginPermissions =
ppapi::PERMISSION_PRIVATE | ppapi::PERMISSION_DEV;
-#endif // defined(ENABLE_PDF)
+#endif // BUILDFLAG(ENABLE_PDF)
content::PepperPluginInfo::GetInterfaceFunc g_pdf_get_interface;
content::PepperPluginInfo::PPP_InitializeModuleFunc g_pdf_initialize_module;
@@ -151,7 +152,7 @@ bool IsWidevineAvailable(base::FilePath* adapter_path,
// not marked internal, aside from being automatically registered, they're just
// regular plugins).
void ComputeBuiltInPlugins(std::vector<content::PepperPluginInfo>* plugins) {
-#if defined(ENABLE_PDF)
+#if BUILDFLAG(ENABLE_PDF)
content::PepperPluginInfo pdf_info;
pdf_info.is_internal = true;
pdf_info.is_out_of_process = true;
@@ -169,7 +170,7 @@ void ComputeBuiltInPlugins(std::vector<content::PepperPluginInfo>* plugins) {
pdf_info.internal_entry_points.shutdown_module = g_pdf_shutdown_module;
pdf_info.permissions = kPDFPluginPermissions;
plugins->push_back(pdf_info);
-#endif // defined(ENABLE_PDF)
+#endif // BUILDFLAG(ENABLE_PDF)
#if !defined(DISABLE_NACL)
// Handle Native Client just like the PDF plugin. This means that it is
« no previous file with comments | « chrome/common/BUILD.gn ('k') | chrome/test/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698