OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2007 David Smith (catfish.man@gmail.com) | 4 * (C) 2007 David Smith (catfish.man@gmail.com) |
5 * Copyright (C) 2003-2013 Apple Inc. All rights reserved. | 5 * Copyright (C) 2003-2013 Apple Inc. All rights reserved. |
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
7 * Copyright (C) 2013 Google Inc. All rights reserved. | 7 * Copyright (C) 2013 Google Inc. All rights reserved. |
8 * | 8 * |
9 * Redistribution and use in source and binary forms, with or without | 9 * Redistribution and use in source and binary forms, with or without |
10 * modification, are permitted provided that the following conditions are | 10 * modification, are permitted provided that the following conditions are |
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 bool updateLogicalWidthAndColumnWidth() override; | 281 bool updateLogicalWidthAndColumnWidth() override; |
282 | 282 |
283 void setLogicalLeftForChild(LayoutBox& child, LayoutUnit logicalLeft); | 283 void setLogicalLeftForChild(LayoutBox& child, LayoutUnit logicalLeft); |
284 void setLogicalTopForChild(LayoutBox& child, LayoutUnit logicalTop); | 284 void setLogicalTopForChild(LayoutBox& child, LayoutUnit logicalTop); |
285 void determineLogicalLeftPositionForChild(LayoutBox& child); | 285 void determineLogicalLeftPositionForChild(LayoutBox& child); |
286 | 286 |
287 private: | 287 private: |
288 bool layoutBlockFlow(bool relayoutChildren, LayoutUnit& pageLogicalHeight, S
ubtreeLayoutScope&); | 288 bool layoutBlockFlow(bool relayoutChildren, LayoutUnit& pageLogicalHeight, S
ubtreeLayoutScope&); |
289 void layoutBlockChildren(bool relayoutChildren, SubtreeLayoutScope&, LayoutU
nit beforeEdge, LayoutUnit afterEdge); | 289 void layoutBlockChildren(bool relayoutChildren, SubtreeLayoutScope&, LayoutU
nit beforeEdge, LayoutUnit afterEdge); |
290 | 290 |
| 291 void markDescendantsWithFloatsForLayoutIfNeeded(LayoutBlockFlow& child, Layo
utUnit newLogicalTop, LayoutUnit previousFloatLogicalBottom); |
| 292 bool positionAndLayoutOnceIfNeeded(LayoutBox& child, LayoutUnit newLogicalTo
p, LayoutUnit& previousFloatLogicalBottom); |
291 void layoutBlockChild(LayoutBox& child, MarginInfo&, LayoutUnit& previousFlo
atLogicalBottom); | 293 void layoutBlockChild(LayoutBox& child, MarginInfo&, LayoutUnit& previousFlo
atLogicalBottom); |
292 void adjustPositionedBlock(LayoutBox& child, const MarginInfo&); | 294 void adjustPositionedBlock(LayoutBox& child, const MarginInfo&); |
293 void adjustFloatingBlock(const MarginInfo&); | 295 void adjustFloatingBlock(const MarginInfo&); |
294 | 296 |
295 LayoutPoint computeLogicalLocationForFloat(const FloatingObject&, LayoutUnit
logicalTopOffset) const; | 297 LayoutPoint computeLogicalLocationForFloat(const FloatingObject&, LayoutUnit
logicalTopOffset) const; |
296 | 298 |
297 void removeFloatingObject(LayoutBox*); | 299 void removeFloatingObject(LayoutBox*); |
298 void removeFloatingObjectsBelow(FloatingObject*, int logicalOffset); | 300 void removeFloatingObjectsBelow(FloatingObject*, int logicalOffset); |
299 | 301 |
300 LayoutUnit getClearDelta(LayoutBox* child, LayoutUnit yPos); | 302 LayoutUnit getClearDelta(LayoutBox* child, LayoutUnit yPos); |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
480 LayoutUnit collapseMargins(LayoutBox& child, MarginInfo&, bool childIsSelfCo
llapsing, bool childDiscardMarginBefore, bool childDiscardMarginAfter); | 482 LayoutUnit collapseMargins(LayoutBox& child, MarginInfo&, bool childIsSelfCo
llapsing, bool childDiscardMarginBefore, bool childDiscardMarginAfter); |
481 LayoutUnit clearFloatsIfNeeded(LayoutBox& child, MarginInfo&, LayoutUnit old
TopPosMargin, LayoutUnit oldTopNegMargin, LayoutUnit yPos, bool childIsSelfColla
psing, bool childDiscardMargin); | 483 LayoutUnit clearFloatsIfNeeded(LayoutBox& child, MarginInfo&, LayoutUnit old
TopPosMargin, LayoutUnit oldTopNegMargin, LayoutUnit yPos, bool childIsSelfColla
psing, bool childDiscardMargin); |
482 LayoutUnit estimateLogicalTopPosition(LayoutBox& child, const MarginInfo&, L
ayoutUnit& estimateWithoutPagination); | 484 LayoutUnit estimateLogicalTopPosition(LayoutBox& child, const MarginInfo&, L
ayoutUnit& estimateWithoutPagination); |
483 void marginBeforeEstimateForChild(LayoutBox&, LayoutUnit&, LayoutUnit&, bool
&) const; | 485 void marginBeforeEstimateForChild(LayoutBox&, LayoutUnit&, LayoutUnit&, bool
&) const; |
484 void handleAfterSideOfBlock(LayoutBox* lastChild, LayoutUnit top, LayoutUnit
bottom, MarginInfo&); | 486 void handleAfterSideOfBlock(LayoutBox* lastChild, LayoutUnit top, LayoutUnit
bottom, MarginInfo&); |
485 void setCollapsedBottomMargin(const MarginInfo&); | 487 void setCollapsedBottomMargin(const MarginInfo&); |
486 | 488 |
487 LayoutUnit applyBeforeBreak(LayoutBox& child, LayoutUnit logicalOffset); //
If the child has a before break, then return a new yPos that shifts to the top o
f the next page/column. | 489 LayoutUnit applyBeforeBreak(LayoutBox& child, LayoutUnit logicalOffset); //
If the child has a before break, then return a new yPos that shifts to the top o
f the next page/column. |
488 LayoutUnit applyAfterBreak(LayoutBox& child, LayoutUnit logicalOffset, Margi
nInfo&); // If the child has an after break, then return a new offset that shift
s to the top of the next page/column. | 490 LayoutUnit applyAfterBreak(LayoutBox& child, LayoutUnit logicalOffset, Margi
nInfo&); // If the child has an after break, then return a new offset that shift
s to the top of the next page/column. |
489 | 491 |
490 LayoutUnit adjustBlockChildForPagination(LayoutUnit logicalTopAfterClear, La
youtUnit estimateWithoutPagination, LayoutBox& child, bool atBeforeSideOfBlock); | 492 LayoutUnit adjustBlockChildForPagination(LayoutUnit logicalTop, LayoutBox& c
hild, bool atBeforeSideOfBlock); |
491 // Computes a deltaOffset value that put a line at the top of the next page
if it doesn't fit on the current page. | 493 // Computes a deltaOffset value that put a line at the top of the next page
if it doesn't fit on the current page. |
492 void adjustLinePositionForPagination(RootInlineBox&, LayoutUnit& deltaOffset
); | 494 void adjustLinePositionForPagination(RootInlineBox&, LayoutUnit& deltaOffset
); |
493 // If the child is unsplittable and can't fit on the current page, return th
e top of the next page/column. | 495 // If the child is unsplittable and can't fit on the current page, return th
e top of the next page/column. |
494 LayoutUnit adjustForUnsplittableChild(LayoutBox&, LayoutUnit logicalOffset,
bool includeMargins = false); | 496 LayoutUnit adjustForUnsplittableChild(LayoutBox&, LayoutUnit logicalOffset,
bool includeMargins = false); |
495 | 497 |
496 // Used to store state between styleWillChange and styleDidChange | 498 // Used to store state between styleWillChange and styleDidChange |
497 static bool s_canPropagateFloatIntoSibling; | 499 static bool s_canPropagateFloatIntoSibling; |
498 | 500 |
499 LayoutBlockFlowRareData& ensureRareData(); | 501 LayoutBlockFlowRareData& ensureRareData(); |
500 | 502 |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
545 | 547 |
546 // END METHODS DEFINED IN LayoutBlockFlowLine | 548 // END METHODS DEFINED IN LayoutBlockFlowLine |
547 | 549 |
548 }; | 550 }; |
549 | 551 |
550 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutBlockFlow, isLayoutBlockFlow()); | 552 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutBlockFlow, isLayoutBlockFlow()); |
551 | 553 |
552 } // namespace blink | 554 } // namespace blink |
553 | 555 |
554 #endif // LayoutBlockFlow_h | 556 #endif // LayoutBlockFlow_h |
OLD | NEW |