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

Side by Side Diff: blimp/client/core/render_widget/blimp_document.cc

Issue 2415633003: blimp: Add mode to use the updated compositing path on the client. (Closed)
Patch Set: Rebase Created 4 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "blimp/client/core/render_widget/blimp_document.h" 5 #include "blimp/client/core/render_widget/blimp_document.h"
6 6
7 #include "base/command_line.h"
7 #include "base/threading/thread_task_runner_handle.h" 8 #include "base/threading/thread_task_runner_handle.h"
8 #include "blimp/client/core/compositor/blimp_compositor_dependencies.h" 9 #include "blimp/client/core/compositor/blimp_compositor_dependencies.h"
9 #include "blimp/client/core/input/blimp_input_manager.h" 10 #include "blimp/client/core/input/blimp_input_manager.h"
10 #include "blimp/client/core/render_widget/blimp_document_manager.h" 11 #include "blimp/client/core/render_widget/blimp_document_manager.h"
12 #include "blimp/client/core/switches/blimp_client_switches.h"
11 #include "cc/layers/layer.h" 13 #include "cc/layers/layer.h"
12 14
13 namespace blimp { 15 namespace blimp {
14 namespace client { 16 namespace client {
15 17
16 BlimpDocument::BlimpDocument(int document_id, 18 BlimpDocument::BlimpDocument(int document_id,
17 BlimpCompositorDependencies* compositor_deps, 19 BlimpCompositorDependencies* compositor_deps,
18 BlimpDocumentManager* document_manager) 20 BlimpDocumentManager* document_manager)
19 : BlimpDocument(document_id, 21 : BlimpDocument(document_id,
20 base::MakeUnique<BlimpCompositor>(compositor_deps, this), 22 base::MakeUnique<BlimpCompositor>(
23 compositor_deps,
24 this,
25 base::CommandLine::ForCurrentProcess()->HasSwitch(
26 switches::kEnableUpdatedCompositingPath)),
21 compositor_deps, 27 compositor_deps,
22 document_manager) {} 28 document_manager) {}
23 29
24 BlimpDocument::BlimpDocument(int document_id, 30 BlimpDocument::BlimpDocument(int document_id,
25 std::unique_ptr<BlimpCompositor> compositor, 31 std::unique_ptr<BlimpCompositor> compositor,
26 BlimpCompositorDependencies* compositor_deps, 32 BlimpCompositorDependencies* compositor_deps,
27 BlimpDocumentManager* document_manager) 33 BlimpDocumentManager* document_manager)
28 : document_id_(document_id), 34 : document_id_(document_id),
29 compositor_(std::move(compositor)), 35 compositor_(std::move(compositor)),
30 manager_(document_manager) { 36 manager_(document_manager) {
(...skipping 28 matching lines...) Expand all
59 manager_->SendCompositorMessage(document_id_, message); 65 manager_->SendCompositorMessage(document_id_, message);
60 } 66 }
61 67
62 void BlimpDocument::SendWebGestureEvent( 68 void BlimpDocument::SendWebGestureEvent(
63 const blink::WebGestureEvent& gesture_event) { 69 const blink::WebGestureEvent& gesture_event) {
64 manager_->SendWebGestureEvent(document_id_, gesture_event); 70 manager_->SendWebGestureEvent(document_id_, gesture_event);
65 } 71 }
66 72
67 } // namespace client 73 } // namespace client
68 } // namespace blimp 74 } // namespace blimp
OLDNEW
« no previous file with comments | « blimp/client/core/render_widget/BUILD.gn ('k') | blimp/client/core/render_widget/blimp_document_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698