OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Apple Inc. All rights reserved. | 2 * Copyright (C) 2012 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
209 return row.visualPointToFlowThreadPoint(visualPoint - row.offsetFromColumnSe
t()); | 209 return row.visualPointToFlowThreadPoint(visualPoint - row.offsetFromColumnSe
t()); |
210 } | 210 } |
211 | 211 |
212 LayoutUnit LayoutMultiColumnSet::pageLogicalTopForOffset(LayoutUnit offset) cons
t | 212 LayoutUnit LayoutMultiColumnSet::pageLogicalTopForOffset(LayoutUnit offset) cons
t |
213 { | 213 { |
214 return fragmentainerGroupAtFlowThreadOffset(offset).columnLogicalTopForOffse
t(offset); | 214 return fragmentainerGroupAtFlowThreadOffset(offset).columnLogicalTopForOffse
t(offset); |
215 } | 215 } |
216 | 216 |
217 bool LayoutMultiColumnSet::recalculateColumnHeight(BalancedColumnHeightCalculati
on calculationMode) | 217 bool LayoutMultiColumnSet::recalculateColumnHeight(BalancedColumnHeightCalculati
on calculationMode) |
218 { | 218 { |
| 219 if (calculationMode == GuessFromFlowThreadPortion) |
| 220 m_tallestUnbreakableLogicalHeight = LayoutUnit(); |
219 bool changed = false; | 221 bool changed = false; |
220 for (auto& group : m_fragmentainerGroups) | 222 for (auto& group : m_fragmentainerGroups) |
221 changed = group.recalculateColumnHeight(calculationMode) || changed; | 223 changed = group.recalculateColumnHeight(calculationMode) || changed; |
222 return changed; | 224 return changed; |
223 } | 225 } |
224 | 226 |
225 void LayoutMultiColumnSet::resetColumnHeight() | 227 void LayoutMultiColumnSet::resetColumnHeight() |
226 { | 228 { |
227 m_fragmentainerGroups.deleteExtraGroups(); | 229 m_fragmentainerGroups.deleteExtraGroups(); |
228 m_fragmentainerGroups.first().resetColumnHeight(); | 230 m_fragmentainerGroups.first().resetColumnHeight(); |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
348 | 350 |
349 LayoutRect LayoutMultiColumnSet::flowThreadPortionRect() const | 351 LayoutRect LayoutMultiColumnSet::flowThreadPortionRect() const |
350 { | 352 { |
351 LayoutRect portionRect(LayoutUnit(), logicalTopInFlowThread(), pageLogicalWi
dth(), logicalHeightInFlowThread()); | 353 LayoutRect portionRect(LayoutUnit(), logicalTopInFlowThread(), pageLogicalWi
dth(), logicalHeightInFlowThread()); |
352 if (!isHorizontalWritingMode()) | 354 if (!isHorizontalWritingMode()) |
353 return portionRect.transposedRect(); | 355 return portionRect.transposedRect(); |
354 return portionRect; | 356 return portionRect; |
355 } | 357 } |
356 | 358 |
357 } | 359 } |
OLD | NEW |