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

Unified Diff: mojo/examples/surfaces_app/surfaces_app.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/examples/surfaces_app/child_app.cc ('k') | mojo/examples/wget/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/examples/surfaces_app/surfaces_app.cc
diff --git a/mojo/examples/surfaces_app/surfaces_app.cc b/mojo/examples/surfaces_app/surfaces_app.cc
index d5f46848e464c02733e5a1bf83549fc2659d11d7..b97e40f9c918106faae05c46309d63266a2d1ef8 100644
--- a/mojo/examples/surfaces_app/surfaces_app.cc
+++ b/mojo/examples/surfaces_app/surfaces_app.cc
@@ -8,8 +8,10 @@
#include "cc/surfaces/surface_id_allocator.h"
#include "mojo/examples/surfaces_app/child.mojom.h"
#include "mojo/examples/surfaces_app/embedder.h"
+#include "mojo/public/c/system/main.h"
#include "mojo/public/cpp/application/application_connection.h"
#include "mojo/public/cpp/application/application_delegate.h"
+#include "mojo/public/cpp/application/application_runner_chromium.h"
#include "mojo/public/cpp/system/core.h"
#include "mojo/services/gles2/command_buffer.mojom.h"
#include "mojo/services/public/cpp/geometry/geometry_type_converters.h"
@@ -153,10 +155,9 @@ class SurfacesApp : public ApplicationDelegate,
};
} // namespace examples
+} // namespace mojo
-// static
-ApplicationDelegate* ApplicationDelegate::Create() {
- return new examples::SurfacesApp();
+MojoResult MojoMain(MojoHandle shell_handle) {
+ mojo::ApplicationRunnerChromium runner(new mojo::examples::SurfacesApp);
+ return runner.Run(shell_handle);
}
-
-} // namespace mojo
« no previous file with comments | « mojo/examples/surfaces_app/child_app.cc ('k') | mojo/examples/wget/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698