[LayoutReloaded] Convert floating left/right stack display boxes absolute to the...
authorzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 29 Mar 2018 03:27:58 +0000 (03:27 +0000)
committerzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 29 Mar 2018 03:27:58 +0000 (03:27 +0000)
commitebb504d4a3d2787e2d1a5171170e51c87d384740
treedb2db2e723200a7a793f278cb9a1e44917d8d17a
parent357f04231256fc447363f81084c7d1137f049e54
[LayoutReloaded] Convert floating left/right stack display boxes absolute to the formatting context's root.
https://bugs.webkit.org/show_bug.cgi?id=184123

Reviewed by Antti Koivisto.

1. The left/right floating array should hold the Display.Box (and not the Layout.Box)
2. Clone the Display.Box and convert its rect absolute to the formatting context's root so that we
don't have to keep converting the coordinates while computing the positions.

* LayoutReloaded/DisplayTree/Box.js:
(Display.Box.prototype.clone):
(Display.Box.prototype.setRect):
* LayoutReloaded/FormattingContext/FloatingContext.js:
(FloatingContext.prototype.computePosition):
(FloatingContext.prototype._positionForFloating):
(FloatingContext.prototype._addFloating):
(FloatingContext.prototype._moveToNextVerticalPosition):
(FloatingContext.prototype._availableSpace):
(FloatingContext.prototype._findFloatingAtVerticalPosition):
(FloatingContext.prototype._adjustedFloatingPosition):
(FloatingContext.prototype._bottom):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@230065 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Tools/ChangeLog
Tools/LayoutReloaded/DisplayTree/Box.js
Tools/LayoutReloaded/FormattingContext/FloatingContext.js