| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2002 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2002 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2002 Dirk Mueller (mueller@kde.org) | 3 * (C) 2002 Dirk Mueller (mueller@kde.org) |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License. | 8 * version 2 of the License. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 }; | 44 }; |
| 45 | 45 |
| 46 enum DistributionDirection { | 46 enum DistributionDirection { |
| 47 StartToEnd, | 47 StartToEnd, |
| 48 EndToStart | 48 EndToStart |
| 49 }; | 49 }; |
| 50 | 50 |
| 51 class TableLayoutAlgorithmAuto final : public TableLayoutAlgorithm { | 51 class TableLayoutAlgorithmAuto final : public TableLayoutAlgorithm { |
| 52 public: | 52 public: |
| 53 TableLayoutAlgorithmAuto(LayoutTable*); | 53 TableLayoutAlgorithmAuto(LayoutTable*); |
| 54 virtual ~TableLayoutAlgorithmAuto(); | 54 ~TableLayoutAlgorithmAuto() override; |
| 55 | 55 |
| 56 virtual void computeIntrinsicLogicalWidths(LayoutUnit& minWidth, LayoutUnit&
maxWidth) override; | 56 void computeIntrinsicLogicalWidths(LayoutUnit& minWidth, LayoutUnit& maxWidt
h) override; |
| 57 virtual void applyPreferredLogicalWidthQuirks(LayoutUnit& minWidth, LayoutUn
it& maxWidth) const override; | 57 void applyPreferredLogicalWidthQuirks(LayoutUnit& minWidth, LayoutUnit& maxW
idth) const override; |
| 58 virtual void layout() override; | 58 void layout() override; |
| 59 virtual void willChangeTableLayout() override { } | 59 void willChangeTableLayout() override { } |
| 60 | 60 |
| 61 private: | 61 private: |
| 62 void fullRecalc(); | 62 void fullRecalc(); |
| 63 void recalcColumn(unsigned effCol); | 63 void recalcColumn(unsigned effCol); |
| 64 | 64 |
| 65 int calcEffectiveLogicalWidth(); | 65 int calcEffectiveLogicalWidth(); |
| 66 void shrinkColumnWidth(const LengthType&, int& available); | 66 void shrinkColumnWidth(const LengthType&, int& available); |
| 67 template<typename Total, LengthType, CellsToProcess, DistributionMode, Distr
ibutionDirection> void distributeWidthToColumns(int& available, Total); | 67 template<typename Total, LengthType, CellsToProcess, DistributionMode, Distr
ibutionDirection> void distributeWidthToColumns(int& available, Total); |
| 68 | 68 |
| 69 void insertSpanCell(LayoutTableCell*); | 69 void insertSpanCell(LayoutTableCell*); |
| (...skipping 24 matching lines...) Expand all Loading... |
| 94 | 94 |
| 95 Vector<Layout, 4> m_layoutStruct; | 95 Vector<Layout, 4> m_layoutStruct; |
| 96 Vector<LayoutTableCell*, 4> m_spanCells; | 96 Vector<LayoutTableCell*, 4> m_spanCells; |
| 97 bool m_hasPercent : 1; | 97 bool m_hasPercent : 1; |
| 98 mutable bool m_effectiveLogicalWidthDirty : 1; | 98 mutable bool m_effectiveLogicalWidthDirty : 1; |
| 99 }; | 99 }; |
| 100 | 100 |
| 101 } // namespace blink | 101 } // namespace blink |
| 102 | 102 |
| 103 #endif // TableLayoutAlgorithmAuto | 103 #endif // TableLayoutAlgorithmAuto |
| OLD | NEW |