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

Side by Side Diff: mojo/examples/wm_flow/wm/wm.cc

Issue 441853002: mojo: first take on removing mojo_main_{chromium,standalone}. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rev 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
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 "mojo/public/cpp/application/application_delegate.h" 5 #include "mojo/public/cpp/application/application_delegate.h"
6 #include "mojo/public/cpp/application/application_export.h"
7 #include "mojo/public/cpp/application/application_impl.h"
8 #include "mojo/public/cpp/application/application_runner_chromium.h"
6 #include "mojo/services/public/cpp/view_manager/view_manager.h" 9 #include "mojo/services/public/cpp/view_manager/view_manager.h"
7 #include "mojo/services/public/cpp/view_manager/view_manager_delegate.h" 10 #include "mojo/services/public/cpp/view_manager/view_manager_delegate.h"
8 #include "mojo/services/public/cpp/view_manager/window_manager_delegate.h" 11 #include "mojo/services/public/cpp/view_manager/window_manager_delegate.h"
9 #include "mojo/services/window_manager/window_manager_app.h" 12 #include "mojo/services/window_manager/window_manager_app.h"
10 13
11 namespace examples { 14 namespace examples {
12 15
13 class SimpleWM : public mojo::ApplicationDelegate, 16 class SimpleWM : public mojo::ApplicationDelegate,
14 public mojo::ViewManagerDelegate, 17 public mojo::ViewManagerDelegate,
15 public mojo::WindowManagerDelegate { 18 public mojo::WindowManagerDelegate {
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 mojo::Node* root_; 74 mojo::Node* root_;
72 mojo::Node* window_container_; 75 mojo::Node* window_container_;
73 76
74 gfx::Point next_window_origin_; 77 gfx::Point next_window_origin_;
75 78
76 DISALLOW_COPY_AND_ASSIGN(SimpleWM); 79 DISALLOW_COPY_AND_ASSIGN(SimpleWM);
77 }; 80 };
78 81
79 } // namespace examples 82 } // namespace examples
80 83
81 namespace mojo { 84 extern "C" APPLICATION_EXPORT MojoResult CDECL MojoMain(
82 85 MojoHandle shell_handle) {
83 // static 86 return mojo::ApplicationRunnerChromium(
84 ApplicationDelegate* ApplicationDelegate::Create() { 87 make_scoped_delegate(new examples::SimpleWM)).Run(shell_handle);
85 return new examples::SimpleWM;
86 } 88 }
87
88 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698