summaryrefslogtreecommitdiffstats
path: root/mojo/runner/desktop/launcher_process.cc
diff options
context:
space:
mode:
Diffstat (limited to 'mojo/runner/desktop/launcher_process.cc')
-rw-r--r--mojo/runner/desktop/launcher_process.cc21
1 files changed, 3 insertions, 18 deletions
diff --git a/mojo/runner/desktop/launcher_process.cc b/mojo/runner/desktop/launcher_process.cc
index d8d9f9a..204b3f7 100644
--- a/mojo/runner/desktop/launcher_process.cc
+++ b/mojo/runner/desktop/launcher_process.cc
@@ -75,23 +75,6 @@ void StopTracingAndFlushToDisk() {
flush_complete_event.Wait();
}
-void StartApp(mojo::runner::Context* context) {
- // If a mojo app isn't specified (i.e. for an apptest), run the mojo shell's
- // window manager.
- GURL app_url(GURL("mojo:window_manager"));
- base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
- base::CommandLine::StringVector args = command_line->GetArgs();
- for (size_t i = 0; i < args.size(); ++i) {
- GURL possible_app(args[i]);
- if (possible_app.SchemeIs("mojo")) {
- app_url = possible_app;
- break;
- }
- }
-
- context->Run(app_url);
-}
-
} // namespace
int LauncherProcessMain(int argc, char** argv) {
@@ -120,7 +103,9 @@ int LauncherProcessMain(int argc, char** argv) {
base::TimeDelta::FromSeconds(5));
}
- message_loop.PostTask(FROM_HERE, base::Bind(&StartApp, &shell_context));
+ message_loop.PostTask(FROM_HERE,
+ base::Bind(&Context::RunCommandLineApplication,
+ base::Unretained(&shell_context)));
message_loop.Run();
// Must be called before |message_loop| is destroyed.