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

Unified Diff: cc/trees/layer_tree_host_unittest.cc

Issue 315393002: Record SkPicture with correct LCD text setting. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: re-add PictureLayer changes Created 6 years, 6 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/picture_layer.cc ('k') | webkit/renderer/compositor_bindings/web_content_layer_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_unittest.cc
diff --git a/cc/trees/layer_tree_host_unittest.cc b/cc/trees/layer_tree_host_unittest.cc
index d2f217cf0c6b29a951025f22b48f4349728bdf94..28c7c79c08897fc7cc4b6eba0fd35addffb7e5af 100644
--- a/cc/trees/layer_tree_host_unittest.cc
+++ b/cc/trees/layer_tree_host_unittest.cc
@@ -2210,7 +2210,11 @@ class LayerTreeHostTestLCDNotification : public LayerTreeHostTest {
};
virtual void SetupTree() OVERRIDE {
- scoped_refptr<ContentLayer> root_layer = ContentLayer::Create(&client_);
+ scoped_refptr<Layer> root_layer;
+ if (layer_tree_host()->settings().impl_side_painting)
+ root_layer = PictureLayer::Create(&client_);
+ else
+ root_layer = ContentLayer::Create(&client_);
root_layer->SetIsDrawable(true);
root_layer->SetBounds(gfx::Size(1, 1));
@@ -2231,7 +2235,7 @@ class LayerTreeHostTestLCDNotification : public LayerTreeHostTest {
virtual void DidCommit() OVERRIDE {
switch (layer_tree_host()->source_frame_number()) {
case 1:
- // The first update consists one LCD notification and one paint.
+ // The first update consists of one LCD notification and one paint.
EXPECT_EQ(1, client_.lcd_notification_count());
EXPECT_EQ(1, client_.paint_count());
// LCD text must have been enabled on the layer.
@@ -2250,7 +2254,7 @@ class LayerTreeHostTestLCDNotification : public LayerTreeHostTest {
// No need to request a commit - setting opacity will do it.
break;
default:
- // Verify that there is not extra commit due to layer invalidation.
+ // Verify that there is no extra commit due to layer invalidation.
EXPECT_EQ(3, layer_tree_host()->source_frame_number());
// LCD notification count should have incremented due to
// change in layer opacity.
@@ -2268,7 +2272,7 @@ class LayerTreeHostTestLCDNotification : public LayerTreeHostTest {
NotificationClient client_;
};
-SINGLE_THREAD_TEST_F(LayerTreeHostTestLCDNotification);
+SINGLE_AND_MULTI_THREAD_TEST_F(LayerTreeHostTestLCDNotification);
// Verify that the BeginFrame notification is used to initiate rendering.
class LayerTreeHostTestBeginFrameNotification : public LayerTreeHostTest {
« no previous file with comments | « cc/layers/picture_layer.cc ('k') | webkit/renderer/compositor_bindings/web_content_layer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698