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

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

Issue 441853002: mojo: first take on removing mojo_main_{chromium,standalone}. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: seperate Run call 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 <stdio.h> 5 #include <stdio.h>
6 #include <string> 6 #include <string>
7 7
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "mojo/aura/context_factory_mojo.h" 9 #include "mojo/aura/context_factory_mojo.h"
10 #include "mojo/aura/screen_mojo.h" 10 #include "mojo/aura/screen_mojo.h"
11 #include "mojo/aura/window_tree_host_mojo.h" 11 #include "mojo/aura/window_tree_host_mojo.h"
12 #include "mojo/aura/window_tree_host_mojo_delegate.h" 12 #include "mojo/aura/window_tree_host_mojo_delegate.h"
13 #include "mojo/public/cpp/application/application_connection.h" 13 #include "mojo/public/cpp/application/application_connection.h"
14 #include "mojo/public/cpp/application/application_delegate.h" 14 #include "mojo/public/cpp/application/application_delegate.h"
15 #include "mojo/public/cpp/application/application_export.h"
DaveMoore 2014/08/18 23:41:03 Nit: I don't think you need application_impl.h. Th
tim (not reviewing) 2014/08/19 00:06:29 Ah, yeah. I was removing it from everywhere possib
16 #include "mojo/public/cpp/application/application_impl.h"
17 #include "mojo/public/cpp/application/application_runner_chromium.h"
15 #include "mojo/public/cpp/system/core.h" 18 #include "mojo/public/cpp/system/core.h"
16 #include "mojo/services/public/cpp/view_manager/view.h" 19 #include "mojo/services/public/cpp/view_manager/view.h"
17 #include "mojo/services/public/cpp/view_manager/view_manager.h" 20 #include "mojo/services/public/cpp/view_manager/view_manager.h"
18 #include "mojo/services/public/cpp/view_manager/view_manager_client_factory.h" 21 #include "mojo/services/public/cpp/view_manager/view_manager_client_factory.h"
19 #include "mojo/services/public/cpp/view_manager/view_manager_delegate.h" 22 #include "mojo/services/public/cpp/view_manager/view_manager_delegate.h"
20 #include "mojo/services/public/interfaces/native_viewport/native_viewport.mojom. h" 23 #include "mojo/services/public/interfaces/native_viewport/native_viewport.mojom. h"
21 #include "ui/aura/client/default_capture_client.h" 24 #include "ui/aura/client/default_capture_client.h"
22 #include "ui/aura/client/window_tree_client.h" 25 #include "ui/aura/client/window_tree_client.h"
23 #include "ui/aura/env.h" 26 #include "ui/aura/env.h"
24 #include "ui/aura/window.h" 27 #include "ui/aura/window.h"
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 View* root_; 196 View* root_;
194 197
195 ViewManagerClientFactory view_manager_client_factory_; 198 ViewManagerClientFactory view_manager_client_factory_;
196 199
197 scoped_ptr<aura::WindowTreeHost> window_tree_host_; 200 scoped_ptr<aura::WindowTreeHost> window_tree_host_;
198 201
199 DISALLOW_COPY_AND_ASSIGN(AuraDemo); 202 DISALLOW_COPY_AND_ASSIGN(AuraDemo);
200 }; 203 };
201 204
202 } // namespace examples 205 } // namespace examples
206 } // namespace mojo
203 207
204 // static 208 extern "C" APPLICATION_EXPORT MojoResult CDECL MojoMain(
205 ApplicationDelegate* ApplicationDelegate::Create() { 209 MojoHandle shell_handle) {
DaveMoore 2014/08/18 23:41:03 I wonder if we should wrap this with our own MojoM
tim (not reviewing) 2014/08/19 00:11:05 Where would this MojoMain live? Right now a nice
DaveMoore 2014/08/19 03:47:34 How about putting MojoMain() in application_runner
206 return new examples::AuraDemo(); 210 mojo::ApplicationRunnerChromium runner(new mojo::examples::AuraDemo());
211 return runner.Run(shell_handle);
207 } 212 }
208
209 } // namespace mojo
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698