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

Unified Diff: chrome/app/chrome_main.cc

Issue 2720863003: Make --headless flag work on Mac (Closed)
Patch Set: revert fix Created 3 years, 10 months 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/BUILD.gn ('k') | headless/lib/browser/headless_content_browser_client.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/app/chrome_main.cc
diff --git a/chrome/app/chrome_main.cc b/chrome/app/chrome_main.cc
index 2210192aa71c441f096499c9c2a25b462bc92c17..0d7a8ad573e4f220d0fff90b8afe7255dba4b18f 100644
--- a/chrome/app/chrome_main.cc
+++ b/chrome/app/chrome_main.cc
@@ -22,6 +22,10 @@
#include "services/service_manager/runner/common/client_util.h"
#endif
+#if defined(OS_MACOSX)
+#include "chrome/app/chrome_main_mac.h"
+#endif
+
#if defined(OS_WIN)
#include "base/debug/dump_without_crashing.h"
#include "base/win/win_util.h"
@@ -93,10 +97,14 @@ int ChromeMain(int argc, const char** argv) {
ALLOW_UNUSED_LOCAL(command_line);
#endif
-#if defined(OS_LINUX)
- if (command_line->HasSwitch(switches::kHeadless))
+#if defined(OS_LINUX) || defined(OS_MACOSX)
+ if (command_line->HasSwitch(switches::kHeadless)) {
+#if defined(OS_MACOSX)
+ SetUpBundleOverrides();
+#endif
return headless::HeadlessShellMain(argc, argv);
-#endif // defined(OS_LINUX)
+ }
+#endif // defined(OS_LINUX) || defined(OS_MACOSX)
#if BUILDFLAG(ENABLE_PACKAGE_MASH_SERVICES)
version_info::Channel channel = chrome::GetChannel();
« no previous file with comments | « chrome/BUILD.gn ('k') | headless/lib/browser/headless_content_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698