From d76806f88db3cf111f2f4bdc6f3cc11f2f865912 Mon Sep 17 00:00:00 2001 From: "shawnsingh@google.com" Date: Wed, 5 Dec 2012 21:41:50 +0000 Subject: Organize internal properties of cc/ layer types One useful way to classify the various properties in cc/ layer data types is: (1) properties given by the user of the cc APIs, and (2) properties that are computed inside of cc code that are needed to correctly draw the layers. This patch organizes properties internally so that as we develop cc code, we are forced to be aware of whether a property is "given" or "computed". Review URL: https://codereview.chromium.org/11280263 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@171323 0039d316-1c4b-4281-b951-d872f2087c98 --- cc/layer_unittest.cc | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'cc/layer_unittest.cc') diff --git a/cc/layer_unittest.cc b/cc/layer_unittest.cc index 6056a94..5267659 100644 --- a/cc/layer_unittest.cc +++ b/cc/layer_unittest.cc @@ -512,16 +512,6 @@ TEST_F(LayerTest, checkPropertyChangeCausesCorrectBehavior) // sanity check of initial test condition EXPECT_FALSE(testLayer->needsDisplay()); - // Test properties that should not call needsDisplay and needsCommit when changed. - EXPECT_SET_NEEDS_COMMIT(0, testLayer->setVisibleContentRect(gfx::Rect(0, 0, 40, 50))); - EXPECT_SET_NEEDS_COMMIT(0, testLayer->setUseLCDText(true)); - EXPECT_SET_NEEDS_COMMIT(0, testLayer->setDrawOpacity(0.5)); - EXPECT_SET_NEEDS_COMMIT(0, testLayer->setRenderTarget(0)); - EXPECT_SET_NEEDS_COMMIT(0, testLayer->setDrawTransform(gfx::Transform())); - EXPECT_SET_NEEDS_COMMIT(0, testLayer->setScreenSpaceTransform(gfx::Transform())); - EXPECT_SET_NEEDS_COMMIT(0, testLayer->setDrawableContentRect(gfx::Rect(4, 5, 6, 7))); - EXPECT_FALSE(testLayer->needsDisplay()); - // Next, test properties that should call setNeedsCommit (but not setNeedsDisplay) // All properties need to be set to new values in order for setNeedsCommit to be called. EXPECT_SET_NEEDS_COMMIT(1, testLayer->setAnchorPoint(gfx::PointF(1.23f, 4.56f))); -- cgit v1.1