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

Side by Side Diff: cc/trees/layer_tree_host_impl.cc

Issue 1821863002: Hook up ui::Compositor to Display's BeginFrameSource (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Display member destruction order Created 4 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 unified diff | Download patch
« no previous file with comments | « cc/trees/layer_tree_host_impl.h ('k') | cc/trees/layer_tree_host_impl_unittest.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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 "cc/trees/layer_tree_host_impl.h" 5 #include "cc/trees/layer_tree_host_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 2350 matching lines...) Expand 10 before | Expand all | Expand 10 after
2361 SetRequiresHighResToDraw(); 2361 SetRequiresHighResToDraw();
2362 2362
2363 return true; 2363 return true;
2364 } 2364 }
2365 2365
2366 void LayerTreeHostImpl::CommitVSyncParameters(base::TimeTicks timebase, 2366 void LayerTreeHostImpl::CommitVSyncParameters(base::TimeTicks timebase,
2367 base::TimeDelta interval) { 2367 base::TimeDelta interval) {
2368 client_->CommitVSyncParameters(timebase, interval); 2368 client_->CommitVSyncParameters(timebase, interval);
2369 } 2369 }
2370 2370
2371 void LayerTreeHostImpl::SetBeginFrameSource(BeginFrameSource* source) {
2372 client_->SetBeginFrameSource(source);
2373 }
2374
2371 void LayerTreeHostImpl::SetViewportSize(const gfx::Size& device_viewport_size) { 2375 void LayerTreeHostImpl::SetViewportSize(const gfx::Size& device_viewport_size) {
2372 if (device_viewport_size == device_viewport_size_) 2376 if (device_viewport_size == device_viewport_size_)
2373 return; 2377 return;
2374 TRACE_EVENT_INSTANT2("cc", "LayerTreeHostImpl::SetViewportSize", 2378 TRACE_EVENT_INSTANT2("cc", "LayerTreeHostImpl::SetViewportSize",
2375 TRACE_EVENT_SCOPE_THREAD, "width", 2379 TRACE_EVENT_SCOPE_THREAD, "width",
2376 device_viewport_size.width(), "height", 2380 device_viewport_size.width(), "height",
2377 device_viewport_size.height()); 2381 device_viewport_size.height());
2378 2382
2379 if (pending_tree_) 2383 if (pending_tree_)
2380 active_tree_->SetViewportSizeInvalid(); 2384 active_tree_->SetViewportSizeInvalid();
(...skipping 1595 matching lines...) Expand 10 before | Expand all | Expand 10 after
3976 return task_runner_provider_->HasImplThread(); 3980 return task_runner_provider_->HasImplThread();
3977 } 3981 }
3978 3982
3979 bool LayerTreeHostImpl::CommitToActiveTree() const { 3983 bool LayerTreeHostImpl::CommitToActiveTree() const {
3980 // In single threaded mode we skip the pending tree and commit directly to the 3984 // In single threaded mode we skip the pending tree and commit directly to the
3981 // active tree. 3985 // active tree.
3982 return !task_runner_provider_->HasImplThread(); 3986 return !task_runner_provider_->HasImplThread();
3983 } 3987 }
3984 3988
3985 } // namespace cc 3989 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl.h ('k') | cc/trees/layer_tree_host_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698