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

Side by Side Diff: cc/layer_tree_host_common_unittest.cc

Issue 11266030: Use gfx:: Geometry types for the resource provider and layer updater classes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: uint8 Created 8 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/layer_painter.h ('k') | cc/layer_tree_host_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 6
7 #include "cc/layer_tree_host_common.h" 7 #include "cc/layer_tree_host_common.h"
8 8
9 #include "cc/content_layer.h" 9 #include "cc/content_layer.h"
10 #include "cc/content_layer_client.h" 10 #include "cc/content_layer_client.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 private: 125 private:
126 virtual ~LayerWithForcedDrawsContent() 126 virtual ~LayerWithForcedDrawsContent()
127 { 127 {
128 } 128 }
129 }; 129 };
130 130
131 class MockContentLayerClient : public ContentLayerClient { 131 class MockContentLayerClient : public ContentLayerClient {
132 public: 132 public:
133 MockContentLayerClient() { } 133 MockContentLayerClient() { }
134 virtual ~MockContentLayerClient() { } 134 virtual ~MockContentLayerClient() { }
135 virtual void paintContents(SkCanvas*, const IntRect& clip, FloatRect& opaque ) OVERRIDE { } 135 virtual void paintContents(SkCanvas*, const gfx::Rect& clip, gfx::RectF& opa que) OVERRIDE { }
136 }; 136 };
137 137
138 scoped_refptr<ContentLayer> createDrawableContentLayer(ContentLayerClient* deleg ate) 138 scoped_refptr<ContentLayer> createDrawableContentLayer(ContentLayerClient* deleg ate)
139 { 139 {
140 scoped_refptr<ContentLayer> toReturn = ContentLayer::create(delegate); 140 scoped_refptr<ContentLayer> toReturn = ContentLayer::create(delegate);
141 toReturn->setIsDrawable(true); 141 toReturn->setIsDrawable(true);
142 return toReturn; 142 return toReturn;
143 } 143 }
144 144
145 TEST(LayerTreeHostCommonTest, verifyTransformsForNoOpLayer) 145 TEST(LayerTreeHostCommonTest, verifyTransformsForNoOpLayer)
(...skipping 3742 matching lines...) Expand 10 before | Expand all | Expand 10 after
3888 int nonexistentId = -1; 3888 int nonexistentId = -1;
3889 EXPECT_EQ(root, LayerTreeHostCommon::findLayerInSubtree(root.get(), root->id ())); 3889 EXPECT_EQ(root, LayerTreeHostCommon::findLayerInSubtree(root.get(), root->id ()));
3890 EXPECT_EQ(child, LayerTreeHostCommon::findLayerInSubtree(root.get(), child-> id())); 3890 EXPECT_EQ(child, LayerTreeHostCommon::findLayerInSubtree(root.get(), child-> id()));
3891 EXPECT_EQ(grandChild, LayerTreeHostCommon::findLayerInSubtree(root.get(), gr andChild->id())); 3891 EXPECT_EQ(grandChild, LayerTreeHostCommon::findLayerInSubtree(root.get(), gr andChild->id()));
3892 EXPECT_EQ(maskLayer, LayerTreeHostCommon::findLayerInSubtree(root.get(), mas kLayer->id())); 3892 EXPECT_EQ(maskLayer, LayerTreeHostCommon::findLayerInSubtree(root.get(), mas kLayer->id()));
3893 EXPECT_EQ(replicaLayer, LayerTreeHostCommon::findLayerInSubtree(root.get(), replicaLayer->id())); 3893 EXPECT_EQ(replicaLayer, LayerTreeHostCommon::findLayerInSubtree(root.get(), replicaLayer->id()));
3894 EXPECT_EQ(0, LayerTreeHostCommon::findLayerInSubtree(root.get(), nonexistent Id)); 3894 EXPECT_EQ(0, LayerTreeHostCommon::findLayerInSubtree(root.get(), nonexistent Id));
3895 } 3895 }
3896 3896
3897 } // namespace 3897 } // namespace
OLDNEW
« no previous file with comments | « cc/layer_painter.h ('k') | cc/layer_tree_host_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698