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

Side by Side Diff: components/html_viewer/html_document.cc

Issue 1406153004: components/mus/public/interfaces View => Window (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Yet another rebase Created 5 years, 2 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
« no previous file with comments | « components/html_viewer/html_document.h ('k') | components/html_viewer/html_frame_apptest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "components/html_viewer/html_document.h" 5 #include "components/html_viewer/html_document.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/single_thread_task_runner.h" 9 #include "base/single_thread_task_runner.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 : app_refcount_(html_document_app->app_lifetime_helper() 100 : app_refcount_(html_document_app->app_lifetime_helper()
101 ->CreateAppRefCount()), 101 ->CreateAppRefCount()),
102 html_document_app_(html_document_app), 102 html_document_app_(html_document_app),
103 connection_(connection), 103 connection_(connection),
104 global_state_(global_state), 104 global_state_(global_state),
105 frame_(nullptr), 105 frame_(nullptr),
106 delete_callback_(delete_callback), 106 delete_callback_(delete_callback),
107 factory_(factory) { 107 factory_(factory) {
108 connection->AddService<web_view::mojom::FrameClient>(this); 108 connection->AddService<web_view::mojom::FrameClient>(this);
109 connection->AddService<AxProvider>(this); 109 connection->AddService<AxProvider>(this);
110 connection->AddService<mojo::ViewTreeClient>(this); 110 connection->AddService<mus::mojom::WindowTreeClient>(this);
111 connection->AddService<devtools_service::DevToolsAgent>(this); 111 connection->AddService<devtools_service::DevToolsAgent>(this);
112 if (IsTestInterfaceEnabled()) 112 if (IsTestInterfaceEnabled())
113 connection->AddService<TestHTMLViewer>(this); 113 connection->AddService<TestHTMLViewer>(this);
114 114
115 resource_waiter_.reset( 115 resource_waiter_.reset(
116 new DocumentResourceWaiter(global_state_, response.Pass(), this)); 116 new DocumentResourceWaiter(global_state_, response.Pass(), this));
117 } 117 }
118 118
119 void HTMLDocument::Destroy() { 119 void HTMLDocument::Destroy() {
120 if (resource_waiter_) { 120 if (resource_waiter_) {
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
307 if (frame_) { 307 if (frame_) {
308 if (frame_->devtools_agent()) 308 if (frame_->devtools_agent())
309 frame_->devtools_agent()->BindToRequest(request.Pass()); 309 frame_->devtools_agent()->BindToRequest(request.Pass());
310 } else { 310 } else {
311 devtools_agent_request_ = request.Pass(); 311 devtools_agent_request_ = request.Pass();
312 } 312 }
313 } 313 }
314 314
315 void HTMLDocument::Create( 315 void HTMLDocument::Create(
316 mojo::ApplicationConnection* connection, 316 mojo::ApplicationConnection* connection,
317 mojo::InterfaceRequest<mojo::ViewTreeClient> request) { 317 mojo::InterfaceRequest<mus::mojom::WindowTreeClient> request) {
318 DCHECK(!transferable_state_.window_tree_delegate_impl); 318 DCHECK(!transferable_state_.window_tree_delegate_impl);
319 transferable_state_.window_tree_delegate_impl.reset( 319 transferable_state_.window_tree_delegate_impl.reset(
320 new WindowTreeDelegateImpl(this)); 320 new WindowTreeDelegateImpl(this));
321 transferable_state_.owns_window_tree_connection = true; 321 transferable_state_.owns_window_tree_connection = true;
322 mus::WindowTreeConnection::Create( 322 mus::WindowTreeConnection::Create(
323 transferable_state_.window_tree_delegate_impl.get(), request.Pass(), 323 transferable_state_.window_tree_delegate_impl.get(), request.Pass(),
324 mus::WindowTreeConnection::CreateType::DONT_WAIT_FOR_EMBED); 324 mus::WindowTreeConnection::CreateType::DONT_WAIT_FOR_EMBED);
325 } 325 }
326 326
327 } // namespace html_viewer 327 } // namespace html_viewer
OLDNEW
« no previous file with comments | « components/html_viewer/html_document.h ('k') | components/html_viewer/html_frame_apptest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698