Changeset 175383 in webkit
- Timestamp:
- Oct 30, 2014 2:39:27 PM (9 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r175381 r175383 1 2014-10-30 Myles C. Maxfield <mmaxfield@apple.com> 2 3 Use references in calculateMinimumPageHeight() for non-optional arguments 4 https://bugs.webkit.org/show_bug.cgi?id=138231 5 6 Reviewed by Dean Jackson. 7 8 No new tests because there is no behavior change. 9 10 * rendering/RenderBlockFlow.cpp: 11 (WebCore::calculateMinimumPageHeight): 12 (WebCore::RenderBlockFlow::adjustLinePositionForPagination): 13 1 14 2014-10-30 Chris Dumez <cdumez@apple.com> 2 15 -
trunk/Source/WebCore/rendering/RenderBlockFlow.cpp
r175352 r175383 1589 1589 } 1590 1590 1591 static inline LayoutUnit calculateMinimumPageHeight(RenderStyle * renderStyle, RootInlineBox*lastLine, LayoutUnit lineTop, LayoutUnit lineBottom)1591 static inline LayoutUnit calculateMinimumPageHeight(RenderStyle& renderStyle, RootInlineBox& lastLine, LayoutUnit lineTop, LayoutUnit lineBottom) 1592 1592 { 1593 1593 // We may require a certain minimum number of lines per page in order to satisfy 1594 1594 // orphans and widows, and that may affect the minimum page height. 1595 unsigned lineCount = std::max<unsigned>(renderStyle ->hasAutoOrphans() ? 1 : renderStyle->orphans(), renderStyle->hasAutoWidows() ? 1 : renderStyle->widows());1595 unsigned lineCount = std::max<unsigned>(renderStyle.hasAutoOrphans() ? 1 : renderStyle.orphans(), renderStyle.hasAutoWidows() ? 1 : renderStyle.widows()); 1596 1596 if (lineCount > 1) { 1597 RootInlineBox* line = lastLine;1597 RootInlineBox* line = &lastLine; 1598 1598 for (unsigned i = 1; i < lineCount && line->prevRootBox(); i++) 1599 1599 line = line->prevRootBox(); … … 1633 1633 LayoutUnit logicalBottom = std::max(lineBox->lineBottomWithLeading(), logicalVisualOverflow.maxY()); 1634 1634 LayoutUnit lineHeight = logicalBottom - logicalOffset; 1635 updateMinimumPageHeight(logicalOffset, calculateMinimumPageHeight( &style(),lineBox, logicalOffset, logicalBottom));1635 updateMinimumPageHeight(logicalOffset, calculateMinimumPageHeight(style(), *lineBox, logicalOffset, logicalBottom)); 1636 1636 logicalOffset += delta; 1637 1637 lineBox->setPaginationStrut(0);
Note: See TracChangeset
for help on using the changeset viewer.