WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
149764
[CSS Grid Layout] Don't need to reset auto-margins during grid items layout
https://bugs.webkit.org/show_bug.cgi?id=149764
Summary
[CSS Grid Layout] Don't need to reset auto-margins during grid items layout
Javier Fernandez
Reported
2015-10-02 15:03:37 PDT
When dealing with auto-margins alignment we were reseting auto values for margins, when grid items don't need to be laid out, just before using them to set the grid items location. This operation can be avoided if we just compute them, when required, during the execution of the stretching logic. This change could help us to avoid performing extra layout calls on some grid items.
Attachments
Patch
(14.08 KB, patch)
2015-10-02 16:32 PDT
,
Javier Fernandez
no flags
Details
Formatted Diff
Diff
Patch
(14.09 KB, patch)
2015-10-06 10:49 PDT
,
Javier Fernandez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Javier Fernandez
Comment 1
2015-10-02 16:32:06 PDT
Created
attachment 262361
[details]
Patch
Darin Adler
Comment 2
2015-10-06 09:22:10 PDT
Comment on
attachment 262361
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=262361&action=review
> Source/WebCore/rendering/RenderGrid.cpp:1505 > + const RenderStyle* parentStyle = &style();
Better to leave this as a reference and put the & at each call site. That helps us in the future when we change the functions to take references instead of pointers.
> Source/WebCore/rendering/RenderGrid.cpp:1527 > + const RenderStyle* parentStyle = &style();
Ditto.
> Source/WebCore/rendering/RenderGrid.cpp:1652 > + // In order to properly adjust the Self Alignment values we need to consider the offset between tracks.
Not sure why it’s good to capitalize the words “Self Alignment”.
Javier Fernandez
Comment 3
2015-10-06 10:49:17 PDT
Created
attachment 262524
[details]
Patch
WebKit Commit Bot
Comment 4
2015-10-06 12:24:23 PDT
Comment on
attachment 262524
[details]
Patch Clearing flags on attachment: 262524 Committed
r190633
: <
http://trac.webkit.org/changeset/190633
>
WebKit Commit Bot
Comment 5
2015-10-06 12:24:27 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug