| Index: mash/common/config.cc
|
| diff --git a/mash/common/config.cc b/mash/common/config.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..48e1354194d3d223bcba7eed482b25d2d1c89e3e
|
| --- /dev/null
|
| +++ b/mash/common/config.cc
|
| @@ -0,0 +1,26 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "mash/common/config.h"
|
| +
|
| +#include "base/command_line.h"
|
| +
|
| +namespace mash {
|
| +namespace common {
|
| +
|
| +const char kWindowManagerSwitch[] = "window-manager";
|
| +
|
| +std::string GetWindowManagerServiceName() {
|
| + if (base::CommandLine::ForCurrentProcess()->HasSwitch(kWindowManagerSwitch)) {
|
| + std::string service_name =
|
| + base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
|
| + kWindowManagerSwitch);
|
| + return service_name;
|
| + }
|
| + // TODO(beng): move this constant to a mojom file in //ash.
|
| + return "ash";
|
| +}
|
| +
|
| +} // namespace common
|
| +} // namespace mash
|
|
|