Move float logical location/dimension methods to FloatingObjects
Created attachment 213273 [details] Patch
Comment on attachment 213273 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=213273&action=review > Source/WebCore/rendering/FloatingObjects.h:152 > + LayoutUnit logicalTopForFloat(const FloatingObject* floatingObject) const { return m_horizontalWritingMode ? floatingObject->y() : floatingObject->x(); } > + LayoutUnit logicalBottomForFloat(const FloatingObject* floatingObject) const { return m_horizontalWritingMode ? floatingObject->maxY() : floatingObject->maxX(); } > + LayoutUnit logicalLeftForFloat(const FloatingObject* floatingObject) const { return m_horizontalWritingMode ? floatingObject->x() : floatingObject->y(); } > + LayoutUnit logicalRightForFloat(const FloatingObject* floatingObject) const { return m_horizontalWritingMode ? floatingObject->maxX() : floatingObject->maxY(); } > + LayoutUnit logicalWidthForFloat(const FloatingObject* floatingObject) const { return m_horizontalWritingMode ? floatingObject->width() : floatingObject->height(); } > + LayoutUnit logicalHeightForFloat(const FloatingObject* floatingObject) const { return m_horizontalWritingMode ? floatingObject->height() : floatingObject->width(); } You should add corresponding methods to RenderBlock. There's no reason to force callers to fetch floatingObjects() just to ask about a float. I think it's fine to add these methods here, but you should add wrappers in RenderBlock so that the call sites don't have to retrieve a floatingObjects().
Actually I guess RenderBlock methods wouldn't even have to call the floatingObjects methods, since a block obviously knows its own writing mode. I don't think these FloatingObjects methods should even exist. Just put them on RenderBlock instead.
Created attachment 213779 [details] Patch Move methods to RenderBlockFlow, now that m_floatingObjects is part of RenderBlockFlow.
Comment on attachment 213779 [details] Patch r=me
Created attachment 213833 [details] Patch rebase
Comment on attachment 213833 [details] Patch Clearing flags on attachment: 213833 Committed r157197: <http://trac.webkit.org/changeset/157197>
All reviewed patches have been landed. Closing bug.