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

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2517953003: Move enable_webrtc to a buildflag header. (Closed)
Patch Set: Fix 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/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index 7f479a7012f1b1c05c6f6e1003bdf67b5fa38c34..e0a6a57da6e74be154f0b8d19775a05e8ee2a4d3 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -179,6 +179,7 @@
#include "device/usb/public/interfaces/device_manager.mojom.h"
#include "extensions/features/features.h"
#include "gin/v8_initializer.h"
+#include "media/media_features.h"
#include "net/base/mime_util.h"
#include "net/base/registry_controlled_domains/registry_controlled_domain.h"
#include "net/cookies/canonical_cookie.h"
@@ -329,7 +330,7 @@
#include "components/spellcheck/browser/spellcheck_message_filter_platform.h"
#endif
-#if defined(ENABLE_WEBRTC)
+#if BUILDFLAG(ENABLE_WEBRTC)
#include "chrome/browser/media/audio_debug_recordings_handler.h"
#include "chrome/browser/media/webrtc/webrtc_logging_handler_host.h"
#endif
@@ -1049,7 +1050,7 @@ void ChromeContentBrowserClient::RenderProcessWillLaunch(
host->AddFilter(new ChromeNetBenchmarkingMessageFilter(profile, context));
host->AddFilter(new prerender::PrerenderMessageFilter(id, profile));
host->AddFilter(new TtsMessageFilter(host->GetBrowserContext()));
-#if defined(ENABLE_WEBRTC)
+#if BUILDFLAG(ENABLE_WEBRTC)
WebRtcLoggingHandlerHost* webrtc_logging_handler_host =
new WebRtcLoggingHandlerHost(id, profile,
g_browser_process->webrtc_log_uploader());
@@ -1606,7 +1607,7 @@ void ChromeContentBrowserClient::AppendExtraCommandLineSwitches(
chromeos::switches::kLoginProfile, login_profile);
#endif
-#if defined(ENABLE_WEBRTC)
+#if BUILDFLAG(ENABLE_WEBRTC)
MaybeCopyDisableWebRtcEncryptionSwitch(command_line,
browser_command_line,
chrome::GetChannel());
@@ -2071,7 +2072,7 @@ bool ChromeContentBrowserClient::AllowWorkerIndexedDB(
return allow;
}
-#if defined(ENABLE_WEBRTC)
+#if BUILDFLAG(ENABLE_WEBRTC)
bool ChromeContentBrowserClient::AllowWebRTCIdentityCache(
const GURL& url,
const GURL& first_party_url,
@@ -2083,7 +2084,7 @@ bool ChromeContentBrowserClient::AllowWebRTCIdentityCache(
return cookie_settings->IsReadingCookieAllowed(url, first_party_url) &&
cookie_settings->IsSettingCookieAllowed(url, first_party_url);
}
-#endif // defined(ENABLE_WEBRTC)
+#endif // BUILDFLAG(ENABLE_WEBRTC)
bool ChromeContentBrowserClient::AllowKeygen(
const GURL& url,
@@ -3259,7 +3260,7 @@ void ChromeContentBrowserClient::OverridePageVisibilityState(
}
}
-#if defined(ENABLE_WEBRTC)
+#if BUILDFLAG(ENABLE_WEBRTC)
void ChromeContentBrowserClient::MaybeCopyDisableWebRtcEncryptionSwitch(
base::CommandLine* to_command_line,
const base::CommandLine& from_command_line,
@@ -3280,7 +3281,7 @@ void ChromeContentBrowserClient::MaybeCopyDisableWebRtcEncryptionSwitch(
arraysize(kWebRtcDevSwitchNames));
}
}
-#endif // defined(ENABLE_WEBRTC)
+#endif // BUILDFLAG(ENABLE_WEBRTC)
std::unique_ptr<content::MemoryCoordinatorDelegate>
ChromeContentBrowserClient::GetMemoryCoordinatorDelegate() {
« no previous file with comments | « chrome/browser/chrome_content_browser_client.h ('k') | chrome/browser/chrome_content_browser_client_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698