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

Unified Diff: cc/layers/render_surface_unittest.cc

Issue 12967018: cc: Avoid pointless gfx::Point/Size contructors when making Rects. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: RectFs as well Created 7 years, 9 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/layers/nine_patch_layer_impl_unittest.cc ('k') | cc/layers/solid_color_layer_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/render_surface_unittest.cc
diff --git a/cc/layers/render_surface_unittest.cc b/cc/layers/render_surface_unittest.cc
index 8720fb07124dd8ad0f7354f331b2f2e137d93f92..70f63f7304c8bbe1b8c03e800d069100ade7833e 100644
--- a/cc/layers/render_surface_unittest.cc
+++ b/cc/layers/render_surface_unittest.cc
@@ -42,7 +42,7 @@ TEST(RenderSurfaceTest, VerifySurfaceChangesAreTrackedProperly) {
owning_layer->CreateRenderSurface();
ASSERT_TRUE(owning_layer->render_surface());
RenderSurfaceImpl* render_surface = owning_layer->render_surface();
- gfx::Rect test_rect = gfx::Rect(gfx::Point(3, 4), gfx::Size(5, 6));
+ gfx::Rect test_rect(3, 4, 5, 6);
owning_layer->ResetAllChangeTrackingForSubtree();
// Currently, the content_rect, clip_rect, and
@@ -93,8 +93,8 @@ TEST(RenderSurfaceTest, SanityCheckSurfaceCreatesCorrectSharedQuadState) {
root_layer->AddChild(owning_layer.Pass());
- gfx::Rect content_rect = gfx::Rect(gfx::Point(), gfx::Size(50, 50));
- gfx::Rect clip_rect = gfx::Rect(gfx::Point(5, 5), gfx::Size(40, 40));
+ gfx::Rect content_rect(0, 0, 50, 50);
+ gfx::Rect clip_rect(5, 5, 40, 40);
gfx::Transform origin;
origin.Translate(30, 40);
@@ -156,7 +156,7 @@ TEST(RenderSurfaceTest, SanityCheckSurfaceCreatesCorrectRenderPass) {
root_layer->AddChild(owning_layer.Pass());
- gfx::Rect content_rect = gfx::Rect(gfx::Point(), gfx::Size(50, 50));
+ gfx::Rect content_rect(0, 0, 50, 50);
gfx::Transform origin;
origin.Translate(30.0, 40.0);
« no previous file with comments | « cc/layers/nine_patch_layer_impl_unittest.cc ('k') | cc/layers/solid_color_layer_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698