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

Side by Side Diff: mojo/shell/public/cpp/lib/content_handler_factory.cc

Issue 1675083002: Rename ApplicationDelegate to ShellClient (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@delegate
Patch Set: . Created 4 years, 10 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
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 <set> 5 #include <set>
6 #include <utility> 6 #include <utility>
7 7
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "base/memory/weak_ptr.h" 11 #include "base/memory/weak_ptr.h"
12 #include "base/message_loop/message_loop.h" 12 #include "base/message_loop/message_loop.h"
13 #include "base/single_thread_task_runner.h" 13 #include "base/single_thread_task_runner.h"
14 #include "base/thread_task_runner_handle.h" 14 #include "base/thread_task_runner_handle.h"
15 #include "base/threading/platform_thread.h" 15 #include "base/threading/platform_thread.h"
16 #include "mojo/message_pump/message_pump_mojo.h" 16 #include "mojo/message_pump/message_pump_mojo.h"
17 #include "mojo/public/cpp/bindings/strong_binding.h" 17 #include "mojo/public/cpp/bindings/strong_binding.h"
18 #include "mojo/shell/public/cpp/application_connection.h" 18 #include "mojo/shell/public/cpp/connection.h"
19 #include "mojo/shell/public/cpp/content_handler_factory.h" 19 #include "mojo/shell/public/cpp/content_handler_factory.h"
20 #include "mojo/shell/public/cpp/interface_factory_impl.h" 20 #include "mojo/shell/public/cpp/interface_factory_impl.h"
21 21
22 namespace mojo { 22 namespace mojo {
23 23
24 namespace { 24 namespace {
25 25
26 class ApplicationThread : public base::PlatformThread::Delegate { 26 class ApplicationThread : public base::PlatformThread::Delegate {
27 public: 27 public:
28 ApplicationThread( 28 ApplicationThread(
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 InterfaceRequest<shell::mojom::Application> application_request, 127 InterfaceRequest<shell::mojom::Application> application_request,
128 URLResponsePtr response) { 128 URLResponsePtr response) {
129 base::MessageLoop loop(common::MessagePumpMojo::Create()); 129 base::MessageLoop loop(common::MessagePumpMojo::Create());
130 auto application = this->CreateApplication(std::move(application_request), 130 auto application = this->CreateApplication(std::move(application_request),
131 std::move(response)); 131 std::move(response));
132 if (application) 132 if (application)
133 loop.Run(); 133 loop.Run();
134 } 134 }
135 135
136 void ContentHandlerFactory::Create( 136 void ContentHandlerFactory::Create(
137 ApplicationConnection* connection, 137 Connection* connection,
138 InterfaceRequest<shell::mojom::ContentHandler> request) { 138 InterfaceRequest<shell::mojom::ContentHandler> request) {
139 new ContentHandlerImpl(delegate_, std::move(request)); 139 new ContentHandlerImpl(delegate_, std::move(request));
140 } 140 }
141 141
142 } // namespace mojo 142 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/shell/public/cpp/lib/application_test_base.cc ('k') | mojo/shell/public/cpp/lib/interface_factory_connector.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698