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 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
349 track_sizing_algorithm_.Reset(); | 349 track_sizing_algorithm_.Reset(); |
350 | 350 |
351 if (Size() != previous_size) | 351 if (Size() != previous_size) |
352 relayout_children = true; | 352 relayout_children = true; |
353 | 353 |
354 LayoutPositionedObjects(relayout_children || IsDocumentElement()); | 354 LayoutPositionedObjects(relayout_children || IsDocumentElement()); |
355 | 355 |
356 ComputeOverflow(old_client_after_edge); | 356 ComputeOverflow(old_client_after_edge); |
357 } | 357 } |
358 | 358 |
359 UpdateLayerTransformAfterLayout(); | |
360 UpdateAfterLayout(); | 359 UpdateAfterLayout(); |
361 | 360 |
362 ClearNeedsLayout(); | 361 ClearNeedsLayout(); |
363 } | 362 } |
364 | 363 |
365 LayoutUnit LayoutGrid::GridGap(GridTrackSizingDirection direction, | 364 LayoutUnit LayoutGrid::GridGap(GridTrackSizingDirection direction, |
366 Optional<LayoutUnit> available_size) const { | 365 Optional<LayoutUnit> available_size) const { |
367 const Length& gap = direction == kForColumns ? StyleRef().GridColumnGap() | 366 const Length& gap = direction == kForColumns ? StyleRef().GridColumnGap() |
368 : StyleRef().GridRowGap(); | 367 : StyleRef().GridRowGap(); |
369 return ValueForLength(gap, available_size.value_or(LayoutUnit())); | 368 return ValueForLength(gap, available_size.value_or(LayoutUnit())); |
(...skipping 2035 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2405 if (direction == kForRows) | 2404 if (direction == kForRows) |
2406 return grid.NumTracks(kForRows); | 2405 return grid.NumTracks(kForRows); |
2407 | 2406 |
2408 return grid.NumTracks(kForRows) | 2407 return grid.NumTracks(kForRows) |
2409 ? grid.NumTracks(kForColumns) | 2408 ? grid.NumTracks(kForColumns) |
2410 : GridPositionsResolver::ExplicitGridColumnCount( | 2409 : GridPositionsResolver::ExplicitGridColumnCount( |
2411 StyleRef(), grid.AutoRepeatTracks(kForColumns)); | 2410 StyleRef(), grid.AutoRepeatTracks(kForColumns)); |
2412 } | 2411 } |
2413 | 2412 |
2414 } // namespace blink | 2413 } // namespace blink |
OLD | NEW |