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

Unified Diff: cc/trees/occlusion_tracker_unittest.cc

Issue 145313006: [#7] Pass gfx structs by const ref (gfx::Size) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 11 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
Index: cc/trees/occlusion_tracker_unittest.cc
diff --git a/cc/trees/occlusion_tracker_unittest.cc b/cc/trees/occlusion_tracker_unittest.cc
index 6b66c28b70a4ed62a38a95864cfaad51df9aa1f6..9c6fa457806b7006bf57d247b2aa6b3523b88747 100644
--- a/cc/trees/occlusion_tracker_unittest.cc
+++ b/cc/trees/occlusion_tracker_unittest.cc
@@ -201,7 +201,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
typename Types::ContentLayerType* CreateRoot(const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
typename Types::ContentLayerPtrType layer(
Types::CreateContentLayer(GetHost()));
typename Types::ContentLayerType* layer_ptr = layer.get();
@@ -218,7 +218,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
typename Types::LayerType* CreateLayer(typename Types::LayerType* parent,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
typename Types::LayerPtrType layer(Types::CreateLayer(GetHost()));
typename Types::LayerType* layer_ptr = layer.get();
SetProperties(layer_ptr, transform, position, bounds);
@@ -229,7 +229,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
typename Types::LayerType* CreateSurface(typename Types::LayerType* parent,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
typename Types::LayerType* layer =
CreateLayer(parent, transform, position, bounds);
layer->SetForceRenderSurface(true);
@@ -240,7 +240,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
typename Types::LayerType* parent,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds,
+ const gfx::Size& bounds,
bool opaque) {
typename Types::ContentLayerPtrType layer(
Types::CreateContentLayer(GetHost()));
@@ -265,7 +265,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
typename Types::LayerType* owning_layer,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
typename Types::ContentLayerPtrType layer(
Types::CreateContentLayer(GetHost()));
typename Types::ContentLayerType* layer_ptr = layer.get();
@@ -276,7 +276,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
typename Types::LayerType* CreateMaskLayer(
typename Types::LayerType* owning_layer,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
typename Types::ContentLayerPtrType layer(
Types::CreateContentLayer(GetHost()));
typename Types::ContentLayerType* layer_ptr = layer.get();
@@ -289,7 +289,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
typename Types::LayerType* parent,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds,
+ const gfx::Size& bounds,
bool opaque) {
typename Types::ContentLayerType* layer =
CreateDrawingLayer(parent, transform, position, bounds, opaque);
@@ -414,7 +414,7 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
void SetBaseProperties(typename Types::LayerType* layer,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
layer->SetTransform(transform);
layer->SetSublayerTransform(gfx::Transform());
layer->SetAnchorPoint(gfx::PointF());
@@ -425,14 +425,14 @@ template <typename Types> class OcclusionTrackerTest : public testing::Test {
void SetProperties(Layer* layer,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
SetBaseProperties(layer, transform, position, bounds);
}
void SetProperties(LayerImpl* layer,
const gfx::Transform& transform,
const gfx::PointF& position,
- gfx::Size bounds) {
+ const gfx::Size& bounds) {
SetBaseProperties(layer, transform, position, bounds);
layer->SetContentBounds(layer->bounds());
« no previous file with comments | « cc/trees/occlusion_tracker.h ('k') | content/browser/android/in_process/synchronous_compositor_output_surface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698