OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "GridPositionsResolver.h" | 5 #include "GridPositionsResolver.h" |
6 | 6 |
| 7 #include <algorithm> |
7 #include "core/layout/LayoutBox.h" | 8 #include "core/layout/LayoutBox.h" |
8 #include "core/style/GridArea.h" | 9 #include "core/style/GridArea.h" |
9 #include <algorithm> | |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 static inline GridTrackSizingDirection directionFromSide( | 13 static inline GridTrackSizingDirection directionFromSide( |
14 GridPositionSide side) { | 14 GridPositionSide side) { |
15 return side == ColumnStartSide || side == ColumnEndSide ? ForColumns | 15 return side == ColumnStartSide || side == ColumnEndSide ? ForColumns |
16 : ForRows; | 16 : ForRows; |
17 } | 17 } |
18 | 18 |
19 static inline String implicitNamedGridLineForSide(const String& lineName, | 19 static inline String implicitNamedGridLineForSide(const String& lineName, |
(...skipping 495 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
515 | 515 |
516 if (endLine < startLine) | 516 if (endLine < startLine) |
517 std::swap(endLine, startLine); | 517 std::swap(endLine, startLine); |
518 else if (endLine == startLine) | 518 else if (endLine == startLine) |
519 endLine = startLine + 1; | 519 endLine = startLine + 1; |
520 | 520 |
521 return GridSpan::untranslatedDefiniteGridSpan(startLine, endLine); | 521 return GridSpan::untranslatedDefiniteGridSpan(startLine, endLine); |
522 } | 522 } |
523 | 523 |
524 } // namespace blink | 524 } // namespace blink |
OLD | NEW |