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

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

Issue 2553093003: Create scroll properties for main thread scrolling even w/o scrolling (Closed)
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
index f89158054fb4bb05d4f06848772ed5a38be4bee5..3e55938b9b403004ab3cb34fd385660173f56523 100644
--- a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
@@ -2696,6 +2696,36 @@ TEST_P(PaintPropertyTreeBuilderTest,
->hasBackgroundAttachmentFixedDescendants());
}
+TEST_P(PaintPropertyTreeBuilderTest, MainThreadScrollReasonsWithoutScrolling) {
+ setBodyInnerHTML(
+ "<style>"
+ " #overflow {"
+ " overflow: scroll;"
+ " width: 100px;"
+ " height: 100px;"
+ " }"
+ " .backgroundAttachmentFixed {"
+ " background-image: url('foo');"
+ " background-attachment: fixed;"
+ " width: 10px;"
+ " height: 10px;"
+ " }"
+ " .forceScroll {"
+ " height: 4000px;"
+ " }"
+ "</style>"
+ "<div id='overflow'>"
+ " <div class='backgroundAttachmentFixed'></div>"
+ "</div>"
+ "<div class='forceScroll'></div>");
+ Element* overflow = document().getElementById("overflow");
+ EXPECT_TRUE(frameScroll()->hasBackgroundAttachmentFixedDescendants());
+ EXPECT_TRUE(overflow->layoutObject()
+ ->paintProperties()
+ ->scroll()
+ ->hasBackgroundAttachmentFixedDescendants());
+}
+
TEST_P(PaintPropertyTreeBuilderTest,
BackgroundAttachmentFixedMainThreadScrollReasonsWithFixedScroller) {
setBodyInnerHTML(
« no previous file with comments | « third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698