Bug 182684 - [css-grid] Apply automatic minimum size clamping to spanning items too
Summary: [css-grid] Apply automatic minimum size clamping to spanning items too
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Manuel Rego Casasnovas
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-02-11 22:56 PST by Manuel Rego Casasnovas
Modified: 2018-02-19 04:11 PST (History)
7 users (show)

See Also:


Attachments
Patch (79.98 KB, patch)
2018-02-11 22:58 PST, Manuel Rego Casasnovas
no flags Details | Formatted Diff | Diff
Patch (79.97 KB, patch)
2018-02-12 00:42 PST, Manuel Rego Casasnovas
no flags Details | Formatted Diff | Diff
Patch for landing (79.94 KB, patch)
2018-02-19 03:34 PST, Manuel Rego Casasnovas
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Manuel Rego Casasnovas 2018-02-11 22:56:42 PST
[css-grid] Apply automatic minimum size clamping to spanning items too
Comment 1 Manuel Rego Casasnovas 2018-02-11 22:58:20 PST
Created attachment 333580 [details]
Patch
Comment 2 Manuel Rego Casasnovas 2018-02-12 00:42:21 PST
Created attachment 333585 [details]
Patch
Comment 3 Javier Fernandez 2018-02-19 03:26:37 PST
Comment on attachment 333585 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=333585&action=review

> Source/WebCore/rendering/GridTrackSizingAlgorithm.cpp:751
> +        const GridSpan& span = m_algorithm.grid().gridItemSpan(child, direction());

We can use 'auto' here too.
Actually, it seems we only use the variable in the loop definition; we could just call gridItemSpan there and avoid this variable.
Comment 4 Manuel Rego Casasnovas 2018-02-19 03:34:24 PST
Created attachment 334148 [details]
Patch for landing
Comment 5 Manuel Rego Casasnovas 2018-02-19 03:34:55 PST
Comment on attachment 333585 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=333585&action=review

Thanks for the review

>> Source/WebCore/rendering/GridTrackSizingAlgorithm.cpp:751
>> +        const GridSpan& span = m_algorithm.grid().gridItemSpan(child, direction());
> 
> We can use 'auto' here too.
> Actually, it seems we only use the variable in the loop definition; we could just call gridItemSpan there and avoid this variable.

True, I've moved the call to the for loop. Nice catch.
Comment 6 WebKit Commit Bot 2018-02-19 04:10:21 PST
Comment on attachment 334148 [details]
Patch for landing

Clearing flags on attachment: 334148

Committed r228661: <https://trac.webkit.org/changeset/228661>
Comment 7 WebKit Commit Bot 2018-02-19 04:10:22 PST
All reviewed patches have been landed.  Closing bug.
Comment 8 Radar WebKit Bug Importer 2018-02-19 04:11:23 PST
<rdar://problem/37666607>