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

Unified Diff: third_party/mojo/src/mojo/public/cpp/application/lib/application_runner.cc

Issue 1139123006: Fork the mojo shell interfaces used by Mandoline. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixes Created 5 years, 7 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
Index: third_party/mojo/src/mojo/public/cpp/application/lib/application_runner.cc
diff --git a/third_party/mojo/src/mojo/public/cpp/application/lib/application_runner.cc b/third_party/mojo/src/mojo/public/cpp/application/lib/application_runner.cc
deleted file mode 100644
index 0737dc76f87f8d922bdbf01f66a1f47410540893..0000000000000000000000000000000000000000
--- a/third_party/mojo/src/mojo/public/cpp/application/lib/application_runner.cc
+++ /dev/null
@@ -1,40 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "mojo/public/cpp/application/application_runner.h"
-
-#include "mojo/public/cpp/application/application_delegate.h"
-#include "mojo/public/cpp/application/application_impl.h"
-#include "mojo/public/cpp/environment/environment.h"
-#include "mojo/public/cpp/utility/run_loop.h"
-
-namespace mojo {
-
-// static
-void ApplicationImpl::Terminate() {
- RunLoop::current()->Quit();
-}
-
-ApplicationRunner::ApplicationRunner(ApplicationDelegate* delegate)
- : delegate_(delegate) {
-}
-ApplicationRunner::~ApplicationRunner() {
- assert(!delegate_);
-}
-
-MojoResult ApplicationRunner::Run(MojoHandle app_request_handle) {
- Environment env;
- {
- RunLoop loop;
- ApplicationImpl app(delegate_, MakeRequest<Application>(MakeScopedHandle(
- MessagePipeHandle(app_request_handle))));
- loop.Run();
- }
-
- delete delegate_;
- delegate_ = nullptr;
- return MOJO_RESULT_OK;
-}
-
-} // namespace mojo

Powered by Google App Engine
This is Rietveld 408576698