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 777 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
788 // Per http://lists.w3.org/Archives/Public/www-style/2013Mar/0589.html,
we clamp negative value to the first line. | 788 // Per http://lists.w3.org/Archives/Public/www-style/2013Mar/0589.html,
we clamp negative value to the first line. |
789 if (endOfTrack < resolvedPosition) | 789 if (endOfTrack < resolvedPosition) |
790 return 0; | 790 return 0; |
791 | 791 |
792 return endOfTrack - resolvedPosition; | 792 return endOfTrack - resolvedPosition; |
793 } | 793 } |
794 case AutoPosition: | 794 case AutoPosition: |
795 // 'auto' depends on the opposite position for resolution (e.g. grid-row
: auto / 1). | 795 // 'auto' depends on the opposite position for resolution (e.g. grid-row
: auto / 1). |
796 ASSERT_NOT_REACHED(); | 796 ASSERT_NOT_REACHED(); |
797 return 0; | 797 return 0; |
| 798 case SpanPosition: |
| 799 // FIXME: Handle span positions (crbug.com/229713). |
| 800 ASSERT_NOT_REACHED(); |
| 801 return 0; |
798 } | 802 } |
799 ASSERT_NOT_REACHED(); | 803 ASSERT_NOT_REACHED(); |
800 return 0; | 804 return 0; |
801 } | 805 } |
802 | 806 |
803 LayoutUnit RenderGrid::gridAreaBreadthForChild(const RenderBox* child, TrackSizi
ngDirection direction, const Vector<GridTrack>& tracks) const | 807 LayoutUnit RenderGrid::gridAreaBreadthForChild(const RenderBox* child, TrackSizi
ngDirection direction, const Vector<GridTrack>& tracks) const |
804 { | 808 { |
805 const GridCoordinate& coordinate = cachedGridCoordinate(child); | 809 const GridCoordinate& coordinate = cachedGridCoordinate(child); |
806 const GridSpan& span = (direction == ForColumns) ? coordinate.columns : coor
dinate.rows; | 810 const GridSpan& span = (direction == ForColumns) ? coordinate.columns : coor
dinate.rows; |
807 LayoutUnit gridAreaBreadth = 0; | 811 LayoutUnit gridAreaBreadth = 0; |
(...skipping 25 matching lines...) Expand all Loading... |
833 if (isOutOfFlowPositioned()) | 837 if (isOutOfFlowPositioned()) |
834 return "RenderGrid (positioned)"; | 838 return "RenderGrid (positioned)"; |
835 if (isAnonymous()) | 839 if (isAnonymous()) |
836 return "RenderGrid (generated)"; | 840 return "RenderGrid (generated)"; |
837 if (isRelPositioned()) | 841 if (isRelPositioned()) |
838 return "RenderGrid (relative positioned)"; | 842 return "RenderGrid (relative positioned)"; |
839 return "RenderGrid"; | 843 return "RenderGrid"; |
840 } | 844 } |
841 | 845 |
842 } // namespace WebCore | 846 } // namespace WebCore |
OLD | NEW |