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

Unified Diff: cc/trees/single_thread_proxy.cc

Issue 2143263002: cc: Remove OutputSurfaceClient::DidSwapBuffers(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: removedidswap: fix-webview-swap Created 4 years, 5 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/single_thread_proxy.h ('k') | content/browser/compositor/gpu_browser_compositor_output_surface.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/single_thread_proxy.cc
diff --git a/cc/trees/single_thread_proxy.cc b/cc/trees/single_thread_proxy.cc
index 37baa50f67b25d9d7faf17c595c3a31cbd40d44f..0e1dee6e959e7f3ddb2abe40f8cab4eb71485506 100644
--- a/cc/trees/single_thread_proxy.cc
+++ b/cc/trees/single_thread_proxy.cc
@@ -512,13 +512,6 @@ void SingleThreadProxy::SetEstimatedParentDrawTime(base::TimeDelta draw_time) {
scheduler_on_impl_thread_->SetEstimatedParentDrawTime(draw_time);
}
-void SingleThreadProxy::DidSwapBuffersOnImplThread() {
- TRACE_EVENT0("cc", "SingleThreadProxy::DidSwapBuffersOnImplThread");
- if (scheduler_on_impl_thread_)
- scheduler_on_impl_thread_->DidSwapBuffers();
- client_->DidPostSwapBuffers();
-}
-
void SingleThreadProxy::DidSwapBuffersCompleteOnImplThread() {
TRACE_EVENT0("cc,benchmark",
"SingleThreadProxy::DidSwapBuffersCompleteOnImplThread");
@@ -696,7 +689,11 @@ DrawResult SingleThreadProxy::DoComposite(LayerTreeHostImpl::FrameData* frame) {
tracked_objects::ScopedTracker tracking_profile8(
FROM_HERE_WITH_EXPLICIT_FUNCTION(
"461509 SingleThreadProxy::DoComposite8"));
- layer_tree_host_impl_->SwapBuffers(*frame);
+ if (layer_tree_host_impl_->SwapBuffers(*frame)) {
+ if (scheduler_on_impl_thread_)
+ scheduler_on_impl_thread_->DidSwapBuffers();
+ client_->DidPostSwapBuffers();
+ }
}
// TODO(robliao): Remove ScopedTracker below once https://crbug.com/461509 is
// fixed.
« no previous file with comments | « cc/trees/single_thread_proxy.h ('k') | content/browser/compositor/gpu_browser_compositor_output_surface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698