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

Side by Side Diff: cc/playback/display_item_list_unittest.cc

Issue 1506203008: Allow background tab titles to use LCD AA. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review comments Created 5 years 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
« no previous file with comments | « cc/playback/compositing_display_item.cc ('k') | cc/proto/display_item.proto » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "cc/playback/display_item_list.h" 5 #include "cc/playback/display_item_list.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "cc/output/filter_operation.h" 9 #include "cc/output/filter_operation.h"
10 #include "cc/output/filter_operations.h" 10 #include "cc/output/filter_operations.h"
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 scoped_refptr<DisplayItemList> list = 192 scoped_refptr<DisplayItemList> list =
193 DisplayItemList::Create(gfx::Rect(layer_size), settings); 193 DisplayItemList::Create(gfx::Rect(layer_size), settings);
194 194
195 // Build the DrawingDisplayItem. 195 // Build the DrawingDisplayItem.
196 AppendFirstSerializationTestPicture(list, layer_size); 196 AppendFirstSerializationTestPicture(list, layer_size);
197 197
198 // Build the CompositingDisplayItem. 198 // Build the CompositingDisplayItem.
199 skia::RefPtr<SkColorFilter> filter = skia::AdoptRef( 199 skia::RefPtr<SkColorFilter> filter = skia::AdoptRef(
200 SkColorFilter::CreateLightingFilter(SK_ColorRED, SK_ColorGREEN)); 200 SkColorFilter::CreateLightingFilter(SK_ColorRED, SK_ColorGREEN));
201 list->CreateAndAppendItem<CompositingDisplayItem>( 201 list->CreateAndAppendItem<CompositingDisplayItem>(
202 kVisualRect, 150, SkXfermode::Mode::kDst_Mode, nullptr, filter); 202 kVisualRect, 150, SkXfermode::Mode::kDst_Mode, nullptr, filter, false);
203 203
204 // Build the second DrawingDisplayItem. 204 // Build the second DrawingDisplayItem.
205 AppendSecondSerializationTestPicture(list, layer_size); 205 AppendSecondSerializationTestPicture(list, layer_size);
206 206
207 // Build the EndCompositingDisplayItem. 207 // Build the EndCompositingDisplayItem.
208 list->CreateAndAppendItem<EndCompositingDisplayItem>(kVisualRect); 208 list->CreateAndAppendItem<EndCompositingDisplayItem>(kVisualRect);
209 209
210 ValidateDisplayItemListSerialization(layer_size, list); 210 ValidateDisplayItemListSerialization(layer_size, list);
211 } 211 }
212 212
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after
667 // picture and items are retained (currently this only happens due to certain 667 // picture and items are retained (currently this only happens due to certain
668 // categories being traced). 668 // categories being traced).
669 list = new DisplayItemList(layer_rect, caching_settings, true); 669 list = new DisplayItemList(layer_rect, caching_settings, true);
670 list->CreateAndAppendItem<DrawingDisplayItem>(kVisualRect, picture); 670 list->CreateAndAppendItem<DrawingDisplayItem>(kVisualRect, picture);
671 list->Finalize(); 671 list->Finalize();
672 memory_usage = list->ApproximateMemoryUsage(); 672 memory_usage = list->ApproximateMemoryUsage();
673 EXPECT_EQ(static_cast<size_t>(0), memory_usage); 673 EXPECT_EQ(static_cast<size_t>(0), memory_usage);
674 } 674 }
675 675
676 } // namespace cc 676 } // namespace cc
OLDNEW
« no previous file with comments | « cc/playback/compositing_display_item.cc ('k') | cc/proto/display_item.proto » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698