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

Side by Side Diff: mojo/examples/demo_launcher/demo_launcher.cc

Issue 441853002: mojo: first take on removing mojo_main_{chromium,standalone}. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « mojo/examples/dbus_echo/dbus_echo_app.cc ('k') | mojo/examples/echo/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/basictypes.h" 5 #include "base/basictypes.h"
6 #include "base/bind.h" 6 #include "base/bind.h"
7 #include "base/run_loop.h" 7 #include "base/run_loop.h"
8 #include "mojo/public/c/system/main.h"
8 #include "mojo/public/cpp/application/application_connection.h" 9 #include "mojo/public/cpp/application/application_connection.h"
9 #include "mojo/public/cpp/application/application_delegate.h" 10 #include "mojo/public/cpp/application/application_delegate.h"
10 #include "mojo/public/cpp/application/application_impl.h" 11 #include "mojo/public/cpp/application/application_impl.h"
12 #include "mojo/public/cpp/application/application_runner_chromium.h"
11 #include "mojo/public/cpp/application/service_provider_impl.h" 13 #include "mojo/public/cpp/application/service_provider_impl.h"
12 #include "mojo/public/interfaces/application/service_provider.mojom.h" 14 #include "mojo/public/interfaces/application/service_provider.mojom.h"
13 #include "mojo/services/public/interfaces/view_manager/view_manager.mojom.h" 15 #include "mojo/services/public/interfaces/view_manager/view_manager.mojom.h"
14 16
15 namespace mojo { 17 namespace mojo {
16 namespace examples { 18 namespace examples {
17 19
18 class DemoLauncher : public ApplicationDelegate { 20 class DemoLauncher : public ApplicationDelegate {
19 public: 21 public:
20 DemoLauncher() {} 22 DemoLauncher() {}
(...skipping 15 matching lines...) Expand all
36 } 38 }
37 39
38 void OnConnect(bool success) {} 40 void OnConnect(bool success) {}
39 41
40 ViewManagerInitServicePtr view_manager_init_; 42 ViewManagerInitServicePtr view_manager_init_;
41 43
42 DISALLOW_COPY_AND_ASSIGN(DemoLauncher); 44 DISALLOW_COPY_AND_ASSIGN(DemoLauncher);
43 }; 45 };
44 46
45 } // namespace examples 47 } // namespace examples
48 } // namespace mojo
46 49
47 // static 50 MojoResult MojoMain(MojoHandle shell_handle) {
48 ApplicationDelegate* ApplicationDelegate::Create() { 51 mojo::ApplicationRunnerChromium runner(new mojo::examples::DemoLauncher);
49 return new examples::DemoLauncher; 52 return runner.Run(shell_handle);
50 } 53 }
51
52 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/examples/dbus_echo/dbus_echo_app.cc ('k') | mojo/examples/echo/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698