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

Unified Diff: mash/common/config.cc

Issue 2710673002: Add Mojo constant for "ash" and replace hardcoded strings (Closed)
Patch Set: s/USE_ASH/OS_CHROMEOS/ 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 | « mash/common/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mash/common/config.cc
diff --git a/mash/common/config.cc b/mash/common/config.cc
index f4e14f7809364732bcc8324771866f4fc8370ae5..b13e15f8e8594c81ed85c1c680f51af1a5610b74 100644
--- a/mash/common/config.cc
+++ b/mash/common/config.cc
@@ -6,6 +6,10 @@
#include "base/command_line.h"
+#if defined(OS_CHROMEOS)
+#include "ash/public/interfaces/constants.mojom.h" // nogncheck
+#endif
+
namespace mash {
namespace common {
@@ -18,8 +22,13 @@ std::string GetWindowManagerServiceName() {
kWindowManagerSwitch);
return service_name;
}
- // TODO(beng): move this constant to a mojom file in //ash.
- return "ash";
+#if defined(OS_CHROMEOS)
+ return ash::mojom::kServiceName;
+#else
+ LOG(FATAL)
+ << "You must specify a window manager e.g. --window-manager=simple_wm";
+ return std::string();
+#endif
}
} // namespace common
« no previous file with comments | « mash/common/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698