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

Unified Diff: components/clipboard/main.cc

Issue 1115363002: mojo: Use ContentHandlers to bundle multiple Applications into a module. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rename redirect -> alias Created 5 years, 8 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 | « components/clipboard/clipboard_application_delegate.cc ('k') | components/core_services/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/clipboard/main.cc
diff --git a/components/clipboard/main.cc b/components/clipboard/main.cc
index 75667d176253ebdf58c619b9be78b93cd3f7e91d..85f942aa8ad3b17998235e3b532954b9202169ea 100644
--- a/components/clipboard/main.cc
+++ b/components/clipboard/main.cc
@@ -2,36 +2,12 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "components/clipboard/clipboard_standalone_impl.h"
+#include "components/clipboard/clipboard_application_delegate.h"
#include "mojo/application/application_runner_chromium.h"
#include "third_party/mojo/src/mojo/public/c/system/main.h"
-#include "third_party/mojo/src/mojo/public/cpp/application/application_connection.h"
-#include "third_party/mojo/src/mojo/public/cpp/application/application_delegate.h"
-#include "third_party/mojo/src/mojo/public/cpp/application/interface_factory.h"
-
-class Delegate : public mojo::ApplicationDelegate,
- public mojo::InterfaceFactory<mojo::Clipboard> {
- public:
- Delegate() {}
- ~Delegate() override {}
-
- // mojo::ApplicationDelegate implementation.
- bool ConfigureIncomingConnection(
- mojo::ApplicationConnection* connection) override {
- connection->AddService(this);
- return true;
- }
-
- // mojo::InterfaceFactory<mojo::Clipboard> implementation.
- void Create(mojo::ApplicationConnection* connection,
- mojo::InterfaceRequest<mojo::Clipboard> request) override {
- // TODO(erg): Write native implementations of the clipboard. For now, we
- // just build a clipboard which doesn't interact with the system.
- new clipboard::ClipboardStandaloneImpl(request.Pass());
- }
-};
MojoResult MojoMain(MojoHandle shell_handle) {
- mojo::ApplicationRunnerChromium runner(new Delegate);
+ mojo::ApplicationRunnerChromium runner(
+ new clipboard::ClipboardApplicationDelegate);
return runner.Run(shell_handle);
}
« no previous file with comments | « components/clipboard/clipboard_application_delegate.cc ('k') | components/core_services/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698