Commit 157fbe18 authored by pilgrim@chromium.org's avatar pilgrim@chromium.org

[Line Layout API] Add border*() to LineLayoutBoxModel

This CL updates callers in InlineFlowBox.

BUG=499321

Review URL: https://codereview.chromium.org/1328723002

git-svn-id: svn://svn.chromium.org/blink/trunk@202005 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent bea249e2
......@@ -108,6 +108,26 @@ public:
return toBoxModel()->paddingAfter();
}
int borderTop() const
{
return toBoxModel()->borderTop();
}
int borderBottom() const
{
return toBoxModel()->borderBottom();
}
int borderLeft() const
{
return toBoxModel()->borderLeft();
}
int borderRight() const
{
return toBoxModel()->borderRight();
}
int borderBefore() const
{
return toBoxModel()->borderBefore();
......
......@@ -624,7 +624,7 @@ void InlineFlowBox::placeBoxesInBlockDirection(LayoutUnit top, LayoutUnit maxHei
const FontMetrics& fontMetrics = curr->layoutObject().style(isFirstLineStyle())->fontMetrics();
newLogicalTop += curr->baselinePosition(baselineType) - fontMetrics.ascent(baselineType);
if (curr->isInlineFlowBox()) {
LayoutBoxModelObject& boxObject = toLayoutBoxModelObject(curr->layoutObject());
LineLayoutBoxModel boxObject = LineLayoutBoxModel(curr->lineLayoutItem());
newLogicalTop -= boxObject.style(isFirstLineStyle())->isHorizontalWritingMode() ? boxObject.borderTop() + boxObject.paddingTop() :
boxObject.borderRight() + boxObject.paddingRight();
borderPaddingHeight = boxObject.borderAndPaddingLogicalHeight();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment