Index: third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp |
diff --git a/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp b/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp |
index 60c874aebb5027c0706117cc38d591c85416f77a..e66af81d6197ba0d34506322771fbe1c11f37b5e 100644 |
--- a/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp |
+++ b/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp |
@@ -806,9 +806,9 @@ void InlineFlowBox::placeBoxesInBlockDirection( |
(rubyBase.lastRootBox() ? rubyBase.lastRootBox()->lineBottom() |
: LayoutUnit()); |
LayoutUnit topRubyBaseLeading = |
- rubyBase.logicalTop() + (rubyBase.firstRootBox() |
- ? rubyBase.firstRootBox()->lineTop() |
- : LayoutUnit()); |
+ rubyBase.logicalTop() + |
+ (rubyBase.firstRootBox() ? rubyBase.firstRootBox()->lineTop() |
+ : LayoutUnit()); |
newLogicalTop += |
!getLineLayoutItem().style()->isFlippedLinesWritingMode() |
? topRubyBaseLeading |
@@ -1358,8 +1358,9 @@ bool InlineFlowBox::nodeAtPoint(HitTestResult& result, |
// Don't add in m_topLeft here, we want coords in the containing block's |
// coordinate space. |
getLineLayoutItem().updateHitTestResult( |
- result, flipForWritingMode(locationInContainer.point() - |
- toLayoutSize(accumulatedOffset))); |
+ result, |
+ flipForWritingMode(locationInContainer.point() - |
+ toLayoutSize(accumulatedOffset))); |
if (result.addNodeToListBasedTestResult(getLineLayoutItem().node(), |
locationInContainer, |
rect) == StopHitTesting) |
@@ -1490,18 +1491,18 @@ LayoutUnit InlineFlowBox::computeOverAnnotationAdjustment( |
if (!rubyRun.style()->isFlippedLinesWritingMode()) { |
LayoutUnit topOfFirstRubyTextLine = |
- rubyText.logicalTop() + (rubyText.firstRootBox() |
- ? rubyText.firstRootBox()->lineTop() |
- : LayoutUnit()); |
+ rubyText.logicalTop() + |
+ (rubyText.firstRootBox() ? rubyText.firstRootBox()->lineTop() |
+ : LayoutUnit()); |
if (topOfFirstRubyTextLine >= 0) |
continue; |
topOfFirstRubyTextLine += curr->logicalTop(); |
result = std::max(result, allowedPosition - topOfFirstRubyTextLine); |
} else { |
LayoutUnit bottomOfLastRubyTextLine = |
- rubyText.logicalTop() + (rubyText.lastRootBox() |
- ? rubyText.lastRootBox()->lineBottom() |
- : rubyText.logicalHeight()); |
+ rubyText.logicalTop() + |
+ (rubyText.lastRootBox() ? rubyText.lastRootBox()->lineBottom() |
+ : rubyText.logicalHeight()); |
if (bottomOfLastRubyTextLine <= curr->logicalHeight()) |
continue; |
bottomOfLastRubyTextLine += curr->logicalTop(); |
@@ -1559,18 +1560,18 @@ LayoutUnit InlineFlowBox::computeUnderAnnotationAdjustment( |
if (rubyRun.style()->isFlippedLinesWritingMode()) { |
LayoutUnit topOfFirstRubyTextLine = |
- rubyText.logicalTop() + (rubyText.firstRootBox() |
- ? rubyText.firstRootBox()->lineTop() |
- : LayoutUnit()); |
+ rubyText.logicalTop() + |
+ (rubyText.firstRootBox() ? rubyText.firstRootBox()->lineTop() |
+ : LayoutUnit()); |
if (topOfFirstRubyTextLine >= 0) |
continue; |
topOfFirstRubyTextLine += curr->logicalTop(); |
result = std::max(result, allowedPosition - topOfFirstRubyTextLine); |
} else { |
LayoutUnit bottomOfLastRubyTextLine = |
- rubyText.logicalTop() + (rubyText.lastRootBox() |
- ? rubyText.lastRootBox()->lineBottom() |
- : rubyText.logicalHeight()); |
+ rubyText.logicalTop() + |
+ (rubyText.lastRootBox() ? rubyText.lastRootBox()->lineBottom() |
+ : rubyText.logicalHeight()); |
if (bottomOfLastRubyTextLine <= curr->logicalHeight()) |
continue; |
bottomOfLastRubyTextLine += curr->logicalTop(); |