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

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

Issue 15435003: cc: Add CopyAsBitmapRequest class to hold the readback callback. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: nolint Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « cc/trees/layer_tree_host.cc ('k') | cc/trees/layer_tree_host_impl.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_common.h" 5 #include "cc/trees/layer_tree_host_common.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/debug/trace_event.h" 9 #include "base/debug/trace_event.h"
10 #include "cc/base/math_util.h" 10 #include "cc/base/math_util.h"
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 // 369 //
370 // These are allowed on the root surface, as they don't require the surface to 370 // These are allowed on the root surface, as they don't require the surface to
371 // be used as a contributing surface in order to apply correctly. 371 // be used as a contributing surface in order to apply correctly.
372 // 372 //
373 373
374 // If we force it. 374 // If we force it.
375 if (layer->force_render_surface()) 375 if (layer->force_render_surface())
376 return true; 376 return true;
377 377
378 // If we'll make a copy of the layer's contents. 378 // If we'll make a copy of the layer's contents.
379 if (layer->HasRequestCopyCallback()) 379 if (layer->HasCopyRequest())
380 return true; 380 return true;
381 381
382 return false; 382 return false;
383 } 383 }
384 384
385 static LayerImpl* NextTargetSurface(LayerImpl* layer) { 385 static LayerImpl* NextTargetSurface(LayerImpl* layer) {
386 return layer->parent() ? layer->parent()->render_target() : 0; 386 return layer->parent() ? layer->parent()->render_target() : 0;
387 } 387 }
388 388
389 // This function returns a translation matrix that can be applied on a vector 389 // This function returns a translation matrix that can be applied on a vector
(...skipping 1431 matching lines...) Expand 10 before | Expand all | Expand 10 after
1821 // At this point, we think the point does hit the touch event handler region 1821 // At this point, we think the point does hit the touch event handler region
1822 // on the layer, but we need to walk up the parents to ensure that the layer 1822 // on the layer, but we need to walk up the parents to ensure that the layer
1823 // was not clipped in such a way that the hit point actually should not hit 1823 // was not clipped in such a way that the hit point actually should not hit
1824 // the layer. 1824 // the layer.
1825 if (PointIsClippedBySurfaceOrClipRect(screen_space_point, layer_impl)) 1825 if (PointIsClippedBySurfaceOrClipRect(screen_space_point, layer_impl))
1826 return false; 1826 return false;
1827 1827
1828 return true; 1828 return true;
1829 } 1829 }
1830 } // namespace cc 1830 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host.cc ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698