OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2011 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 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 SECURITY_DCHECK(!m_gridIsDirty); | 87 SECURITY_DCHECK(!m_gridIsDirty); |
88 return m_grid.gridItemPaintOrder(*layoutBox); | 88 return m_grid.gridItemPaintOrder(*layoutBox); |
89 } | 89 } |
90 | 90 |
91 size_t autoRepeatCountForDirection(GridTrackSizingDirection direction) const { | 91 size_t autoRepeatCountForDirection(GridTrackSizingDirection direction) const { |
92 return m_grid.autoRepeatTracks(direction); | 92 return m_grid.autoRepeatTracks(direction); |
93 } | 93 } |
94 | 94 |
95 LayoutUnit translateRTLCoordinate(LayoutUnit) const; | 95 LayoutUnit translateRTLCoordinate(LayoutUnit) const; |
96 | 96 |
| 97 protected: |
| 98 ItemPosition selfAlignmentNormalBehavior() const override { |
| 99 return ItemPositionStretch; |
| 100 } |
| 101 |
97 private: | 102 private: |
98 bool isOfType(LayoutObjectType type) const override { | 103 bool isOfType(LayoutObjectType type) const override { |
99 return type == LayoutObjectLayoutGrid || LayoutBlock::isOfType(type); | 104 return type == LayoutObjectLayoutGrid || LayoutBlock::isOfType(type); |
100 } | 105 } |
101 void computeIntrinsicLogicalWidths( | 106 void computeIntrinsicLogicalWidths( |
102 LayoutUnit& minLogicalWidth, | 107 LayoutUnit& minLogicalWidth, |
103 LayoutUnit& maxLogicalWidth) const override; | 108 LayoutUnit& maxLogicalWidth) const override; |
104 | 109 |
105 LayoutUnit computeIntrinsicLogicalContentHeightUsing( | 110 LayoutUnit computeIntrinsicLogicalContentHeightUsing( |
106 const Length& logicalHeightLength, | 111 const Length& logicalHeightLength, |
(...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
424 LayoutUnit m_maxContentHeight{-1}; | 429 LayoutUnit m_maxContentHeight{-1}; |
425 | 430 |
426 Optional<bool> m_hasDefiniteLogicalHeight; | 431 Optional<bool> m_hasDefiniteLogicalHeight; |
427 }; | 432 }; |
428 | 433 |
429 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutGrid, isLayoutGrid()); | 434 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutGrid, isLayoutGrid()); |
430 | 435 |
431 } // namespace blink | 436 } // namespace blink |
432 | 437 |
433 #endif // LayoutGrid_h | 438 #endif // LayoutGrid_h |
OLD | NEW |