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

Unified Diff: cc/test/layer_tree_host_common_test.h

Issue 1491033002: Create RenderSurface on Effect Tree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@alwayspt
Patch Set: fix for crash Created 5 years 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/test/layer_test_common.h ('k') | cc/test/layer_tree_host_common_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/layer_tree_host_common_test.h
diff --git a/cc/test/layer_tree_host_common_test.h b/cc/test/layer_tree_host_common_test.h
index f8f1a02fe5d2f061450360127531e49b5c2ff2d4..2a66715f549b16c3e1afe91c68e719344ea37b14 100644
--- a/cc/test/layer_tree_host_common_test.h
+++ b/cc/test/layer_tree_host_common_test.h
@@ -5,6 +5,7 @@
#ifndef CC_TEST_LAYER_TREE_HOST_COMMON_TEST_H_
#define CC_TEST_LAYER_TREE_HOST_COMMON_TEST_H_
+#include <algorithm>
#include <vector>
#include "base/memory/scoped_ptr.h"
@@ -66,6 +67,14 @@ class LayerTreeHostCommonTestBase : public LayerTestCommon::LayerImplTest {
const gfx::PointF& position,
const gfx::Size& bounds,
bool flatten_transform,
+ bool is_3d_sorted);
+
+ void SetLayerPropertiesForTesting(LayerImpl* layer,
+ const gfx::Transform& transform,
+ const gfx::Point3F& transform_origin,
+ const gfx::PointF& position,
+ const gfx::Size& bounds,
+ bool flatten_transform,
bool is_3d_sorted,
bool create_render_surface);
@@ -118,6 +127,15 @@ class LayerTreeHostCommonTestBase : public LayerTestCommon::LayerImplTest {
return render_surface_layer_list_impl_.get();
}
+ LayerImplList* update_layer_list_impl() const {
+ return update_layer_list_impl_.get();
+ }
+ bool UpdateLayerListImplContains(int id) const {
+ return std::count_if(
+ update_layer_list_impl_->begin(), update_layer_list_impl_->end(),
+ [id](LayerImpl* layer) { return layer->id() == id; }) != 0;
+ }
+
const LayerList& update_layer_list() const { return update_layer_list_; }
bool UpdateLayerListContains(int id) const;
@@ -130,6 +148,7 @@ class LayerTreeHostCommonTestBase : public LayerTestCommon::LayerImplTest {
private:
scoped_ptr<std::vector<LayerImpl*>> render_surface_layer_list_impl_;
LayerList update_layer_list_;
+ scoped_ptr<LayerImplList> update_layer_list_impl_;
LayerSettings layer_settings_;
int render_surface_layer_list_count_;
« no previous file with comments | « cc/test/layer_test_common.h ('k') | cc/test/layer_tree_host_common_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698