| 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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 // and any other type of operation that requires mapping from flow thread coordi
nates to visual | 53 // and any other type of operation that requires mapping from flow thread coordi
nates to visual |
| 54 // coordinates. | 54 // coordinates. |
| 55 // | 55 // |
| 56 // Columns are normally laid out in the inline progression direction, but if the
multicol container | 56 // Columns are normally laid out in the inline progression direction, but if the
multicol container |
| 57 // is inside another fragmentation context (e.g. paged media, or an another mult
icol container), we | 57 // is inside another fragmentation context (e.g. paged media, or an another mult
icol container), we |
| 58 // may need to group the columns, so that we get one MultiColumnFragmentainerGro
up for each outer | 58 // may need to group the columns, so that we get one MultiColumnFragmentainerGro
up for each outer |
| 59 // fragmentainer (page / column) that the inner multicol container lives in. Eac
h fragmentainer | 59 // fragmentainer (page / column) that the inner multicol container lives in. Eac
h fragmentainer |
| 60 // group has its own column height, but the column height is uniform within a gr
oup. | 60 // group has its own column height, but the column height is uniform within a gr
oup. |
| 61 class LayoutMultiColumnSet : public LayoutRegion { | 61 class LayoutMultiColumnSet : public LayoutRegion { |
| 62 public: | 62 public: |
| 63 static LayoutMultiColumnSet* createAnonymous(LayoutFlowThread&, const Layout
Style& parentStyle); | 63 static LayoutMultiColumnSet* createAnonymous(LayoutFlowThread&, const Comput
edStyle& parentStyle); |
| 64 | 64 |
| 65 const MultiColumnFragmentainerGroup& firstFragmentainerGroup() const { retur
n m_fragmentainerGroups.first(); } | 65 const MultiColumnFragmentainerGroup& firstFragmentainerGroup() const { retur
n m_fragmentainerGroups.first(); } |
| 66 const MultiColumnFragmentainerGroup& lastFragmentainerGroup() const { return
m_fragmentainerGroups.last(); } | 66 const MultiColumnFragmentainerGroup& lastFragmentainerGroup() const { return
m_fragmentainerGroups.last(); } |
| 67 MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(LayoutUn
it); | 67 MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(LayoutUn
it); |
| 68 const MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(La
youtUnit) const; | 68 const MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(La
youtUnit) const; |
| 69 const MultiColumnFragmentainerGroup& fragmentainerGroupAtVisualPoint(const L
ayoutPoint&) const; | 69 const MultiColumnFragmentainerGroup& fragmentainerGroupAtVisualPoint(const L
ayoutPoint&) const; |
| 70 | 70 |
| 71 virtual bool isOfType(LayoutObjectType type) const override { return type ==
LayoutObjectLayoutMultiColumnSet || LayoutRegion::isOfType(type); } | 71 virtual bool isOfType(LayoutObjectType type) const override { return type ==
LayoutObjectLayoutMultiColumnSet || LayoutRegion::isOfType(type); } |
| 72 | 72 |
| 73 virtual LayoutUnit pageLogicalWidth() const final { return flowThread()->log
icalWidth(); } | 73 virtual LayoutUnit pageLogicalWidth() const final { return flowThread()->log
icalWidth(); } |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 171 | 171 |
| 172 MultiColumnFragmentainerGroupList m_fragmentainerGroups; | 172 MultiColumnFragmentainerGroupList m_fragmentainerGroups; |
| 173 }; | 173 }; |
| 174 | 174 |
| 175 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutMultiColumnSet, isLayoutMultiColumnSet()); | 175 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutMultiColumnSet, isLayoutMultiColumnSet()); |
| 176 | 176 |
| 177 } // namespace blink | 177 } // namespace blink |
| 178 | 178 |
| 179 #endif // LayoutMultiColumnSet_h | 179 #endif // LayoutMultiColumnSet_h |
| 180 | 180 |
| OLD | NEW |