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

Unified Diff: cc/trees/layer_tree_host_common.h

Issue 1869983003: cc: Clean up helper function from layer tree host common (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@targetid
Patch Set: rebase 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/trees/damage_tracker_unittest.cc ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_common.h
diff --git a/cc/trees/layer_tree_host_common.h b/cc/trees/layer_tree_host_common.h
index 090cf8c543777e43e60a117aa418591e3fff8068..c136f960d3abbd3e942f2a817097307a879458ab 100644
--- a/cc/trees/layer_tree_host_common.h
+++ b/cc/trees/layer_tree_host_common.h
@@ -140,10 +140,6 @@ class CC_EXPORT LayerTreeHostCommon {
static void CalculateDrawProperties(
CalcDrawPropsImplInputsForTesting* inputs);
- template <typename LayerType>
- static bool RenderSurfaceContributesToTarget(LayerType*,
- int target_surface_layer_id);
-
template <typename Function>
static void CallFunctionForEveryLayer(LayerTreeHost* layer,
const Function& function,
@@ -154,15 +150,6 @@ class CC_EXPORT LayerTreeHostCommon {
const Function& function,
const CallFunctionLayerType& type);
- static Layer* get_layer_as_raw_ptr(const LayerList& layers, size_t index) {
- return layers[index].get();
- }
-
- static LayerImpl* get_layer_as_raw_ptr(const LayerImplList& layers,
- size_t index) {
- return layers[index];
- }
-
struct CC_EXPORT ScrollUpdateInfo {
int layer_id;
// TODO(miletus): Use ScrollOffset once LayerTreeHost/Blink fully supports
@@ -194,24 +181,6 @@ struct CC_EXPORT ScrollAndScaleSet {
DISALLOW_COPY_AND_ASSIGN(ScrollAndScaleSet);
};
-template <typename LayerType>
-bool LayerTreeHostCommon::RenderSurfaceContributesToTarget(
- LayerType* layer,
- int target_surface_layer_id) {
- // A layer will either contribute its own content, or its render surface's
- // content, to the target surface. The layer contributes its surface's content
- // when both the following are true:
- // (1) The layer actually has a render surface and rendering into that
- // surface, and
- // (2) The layer's render surface is not the same as the target surface.
- //
- // Otherwise, the layer just contributes itself to the target surface.
-
- return layer->has_render_surface() &&
- layer->render_target() == layer->render_surface() &&
- layer->id() != target_surface_layer_id;
-}
-
template <typename LayerType, typename Function>
static void CallFunctionForLayer(LayerType* layer,
const Function& function,
« no previous file with comments | « cc/trees/damage_tracker_unittest.cc ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698