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

Unified Diff: third_party/WebKit/Source/core/paint/PaintControllerPaintTest.cpp

Issue 1425593007: Separate display item clients for negative and normal/positive z-order children (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/paint/PaintControllerPaintTest.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.cpp b/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.cpp
index 143a3c793260212bc9a1d91d90bebf7a8ad56a23..31688e4edf4b025018b127eac46947d09abcbf1d 100644
--- a/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.cpp
@@ -26,13 +26,14 @@ TEST_P(PaintControllerPaintTestForSlimmingPaintV1AndV2, FullDocumentPaintingWith
Element& div = *toElement(document().body()->firstChild());
LayoutObject& divLayoutObject = *document().body()->firstChild()->layoutObject();
InlineTextBox& textInlineBox = *toLayoutText(div.firstChild()->layoutObject())->firstTextBox();
+ DisplayItemClientWrapper rootLayerClient(rootLayer.displayItemClientForNormalAndPositiveZOrderChildren());
if (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled()) {
EXPECT_DISPLAY_LIST(rootPaintController().displayItemList(), 4,
TestDisplayItem(layoutView(), backgroundType),
- TestDisplayItem(rootLayer, subsequenceType),
+ TestDisplayItem(rootLayerClient, DisplayItem::Subsequence),
TestDisplayItem(textInlineBox, foregroundType),
- TestDisplayItem(rootLayer, endSubsequenceType));
+ TestDisplayItem(rootLayerClient, DisplayItem::EndSubsequence));
} else {
GraphicsContext context(rootPaintController());
PaintLayerPaintingInfo paintingInfo(&rootLayer, LayoutRect(0, 0, 800, 600), GlobalPaintNormalPhase, LayoutSize());
@@ -50,10 +51,10 @@ TEST_P(PaintControllerPaintTestForSlimmingPaintV1AndV2, FullDocumentPaintingWith
if (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled()) {
EXPECT_DISPLAY_LIST(rootPaintController().displayItemList(), 5,
TestDisplayItem(layoutView(), backgroundType),
- TestDisplayItem(rootLayer, subsequenceType),
+ TestDisplayItem(rootLayerClient, DisplayItem::Subsequence),
TestDisplayItem(textInlineBox, foregroundType),
TestDisplayItem(divLayoutObject, DisplayItem::Caret), // New!
- TestDisplayItem(rootLayer, endSubsequenceType));
+ TestDisplayItem(rootLayerClient, DisplayItem::EndSubsequence));
} else {
GraphicsContext context(rootPaintController());
PaintLayerPaintingInfo paintingInfo(&rootLayer, LayoutRect(0, 0, 800, 600), GlobalPaintNormalPhase, LayoutSize());
@@ -75,13 +76,14 @@ TEST_P(PaintControllerPaintTestForSlimmingPaintV1AndV2, InlineRelayout)
LayoutBlock& divBlock = *toLayoutBlock(document().body()->firstChild()->layoutObject());
LayoutText& text = *toLayoutText(divBlock.firstChild());
InlineTextBox& firstTextBox = *text.firstTextBox();
+ DisplayItemClientWrapper rootLayerClient(rootLayer.displayItemClientForNormalAndPositiveZOrderChildren());
if (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled()) {
EXPECT_DISPLAY_LIST(rootPaintController().displayItemList(), 4,
TestDisplayItem(layoutView(), backgroundType),
- TestDisplayItem(rootLayer, subsequenceType),
+ TestDisplayItem(rootLayerClient, DisplayItem::Subsequence),
TestDisplayItem(firstTextBox, foregroundType),
- TestDisplayItem(rootLayer, endSubsequenceType));
+ TestDisplayItem(rootLayerClient, DisplayItem::EndSubsequence));
} else {
GraphicsContext context(rootPaintController());
PaintLayerPaintingInfo paintingInfo(&rootLayer, LayoutRect(0, 0, 800, 600), GlobalPaintNormalPhase, LayoutSize());
@@ -103,10 +105,10 @@ TEST_P(PaintControllerPaintTestForSlimmingPaintV1AndV2, InlineRelayout)
if (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled()) {
EXPECT_DISPLAY_LIST(rootPaintController().displayItemList(), 5,
TestDisplayItem(layoutView(), backgroundType),
- TestDisplayItem(rootLayer, subsequenceType),
+ TestDisplayItem(rootLayerClient, DisplayItem::Subsequence),
TestDisplayItem(newFirstTextBox, foregroundType),
TestDisplayItem(secondTextBox, foregroundType),
- TestDisplayItem(rootLayer, endSubsequenceType));
+ TestDisplayItem(rootLayerClient, DisplayItem::EndSubsequence));
} else {
GraphicsContext context(rootPaintController());
PaintLayerPaintingInfo paintingInfo(&rootLayer, LayoutRect(0, 0, 800, 600), GlobalPaintNormalPhase, LayoutSize());

Powered by Google App Engine
This is Rietveld 408576698