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

Unified Diff: cc/trees/thread_proxy.cc

Issue 15855008: cc: Call ManageTiles explicitly (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 6 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 | « cc/trees/thread_proxy.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/thread_proxy.cc
diff --git a/cc/trees/thread_proxy.cc b/cc/trees/thread_proxy.cc
index d1c44712c33643e15e009eb7b28497b470949676..5f92c61099806816bf8b353462a724fed9ab9e85 100644
--- a/cc/trees/thread_proxy.cc
+++ b/cc/trees/thread_proxy.cc
@@ -384,21 +384,6 @@ void ThreadProxy::SetNeedsCommitOnImplThread() {
scheduler_on_impl_thread_->SetNeedsCommit();
}
-void ThreadProxy::SetNeedsManageTilesOnImplThread() {
- if (manage_tiles_pending_)
- return;
- Proxy::ImplThread()->PostTask(
- base::Bind(&ThreadProxy::ManageTilesOnImplThread, impl_thread_weak_ptr_));
- manage_tiles_pending_ = true;
-}
-
-void ThreadProxy::ManageTilesOnImplThread() {
- // TODO(nduca): If needed, move this into CCSchedulerStateMachine.
- manage_tiles_pending_ = false;
- if (layer_tree_host_impl_)
- layer_tree_host_impl_->ManageTiles();
-}
-
void ThreadProxy::PostAnimationEventsToMainThreadOnImplThread(
scoped_ptr<AnimationEventsVector> events,
base::Time wall_clock_time) {
@@ -986,6 +971,12 @@ ThreadProxy::ScheduledActionDrawAndSwapInternal(bool forced_draw) {
if (draw_frame)
CheckOutputSurfaceStatusOnImplThread();
+ // Update the tile state after drawing. This prevents manage tiles from
+ // being in the critical path for getting things on screen, but still
+ // makes sure that tile state is updated on a semi-regular basis.
+ if (layer_tree_host_impl_->settings().impl_side_painting)
+ layer_tree_host_impl_->ManageTiles();
+
return result;
}
« no previous file with comments | « cc/trees/thread_proxy.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698