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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutFlowThread.cpp

Issue 2250713002: Handle auto-positioned out-of-flow objects inside multicol containers correctly. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: code review Created 4 years, 4 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/LayoutFlowThread.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/layout/LayoutFlowThread.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutFlowThread.cpp b/third_party/WebKit/Source/core/layout/LayoutFlowThread.cpp
index 5eae393e2aa636d4e15d5605d726220a4a2fb9e6..3002b95552d8e3b2389fee4d20dee9fd8c2df18d 100644
--- a/third_party/WebKit/Source/core/layout/LayoutFlowThread.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutFlowThread.cpp
@@ -187,6 +187,24 @@ LayoutRect LayoutFlowThread::fragmentsBoundingBox(const LayoutRect& layerBoundin
return result;
}
+void LayoutFlowThread::flowThreadToContainingCoordinateSpace(LayoutUnit& blockPosition, LayoutUnit& inlinePosition) const
+{
+ LayoutPoint position(inlinePosition, blockPosition);
+ // First we have to make |position| physical, because that's what offsetLeft() expects and returns.
+ if (!isHorizontalWritingMode())
+ position = position.transposedPoint();
+ position = flipForWritingMode(position);
+
+ position.move(columnOffset(position));
+
+ // Make |position| logical again, and read out the values.
+ position = flipForWritingMode(position);
+ if (!isHorizontalWritingMode())
+ position = position.transposedPoint();
+ blockPosition = position.y();
+ inlinePosition = position.x();
+}
+
void LayoutFlowThread::MultiColumnSetSearchAdapter::collectIfNeeded(const MultiColumnSetInterval& interval)
{
if (m_result)
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutFlowThread.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698