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

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

Issue 2774443004: Fix overflow rect calculation for float in rtl container. (Closed)
Patch Set: Created 3 years, 9 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 | « third_party/WebKit/Source/core/layout/LayoutBlockFlow.h ('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/PaintLayerScrollableAreaTest.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintLayerScrollableAreaTest.cpp b/third_party/WebKit/Source/core/paint/PaintLayerScrollableAreaTest.cpp
index b0f796cc3b4d8b7b6ee4a481e9f57a65d7158d69..5680f37c60fdccd9732bf606141197484074b308 100644
--- a/third_party/WebKit/Source/core/paint/PaintLayerScrollableAreaTest.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintLayerScrollableAreaTest.cpp
@@ -596,4 +596,30 @@ TEST_F(PaintLayerScrollableAreaTest, ShowAutoScrollbarsForVisibleContent) {
ASSERT_TRUE(scrollableArea);
EXPECT_TRUE(scrollableArea->hasVerticalScrollbar());
}
+
+TEST_F(PaintLayerScrollableAreaTest, FloatOverflowInRtlContainer) {
+ RuntimeEnabledFeatures::setOverlayScrollbarsEnabled(false);
+ setBodyInnerHTML(
+ "<!DOCTYPE html>"
+ "<style>"
+ "#container {"
+ " width: 200px;"
+ " overflow-x: auto;"
+ " overflow-y: scroll;"
+ " direction: rtl;"
+ "}"
+ "</style>"
+ "<div id='container'>"
+ " <div style='float:left'>"
+ "lorem ipsum"
+ " </div>"
+ "</div>");
+ document().view()->updateAllLifecyclePhases();
+ Element* container = document().getElementById("container");
+ ASSERT_TRUE(container);
+ PaintLayerScrollableArea* scrollableArea =
+ toLayoutBoxModelObject(container->layoutObject())->getScrollableArea();
+ ASSERT_TRUE(scrollableArea);
+ EXPECT_FALSE(scrollableArea->hasHorizontalScrollbar());
+}
}
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutBlockFlow.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698