Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(413)

Issue 198703004: [CSS Grid Layout] Fix issues adding new items to grid (Closed)

Created:
6 years, 9 months ago by Manuel Rego
Modified:
6 years, 9 months ago
CC:
blink-reviews, jfernandez, zoltan1, svillar, bemjb+rendering_chromium.org, leviw+renderwatch, eae+blinkwatch, jchaffraix+rendering, dsinclair, pdr.
Base URL:
https://chromium.googlesource.com/chromium/blink.git@enable-css-grid-layout
Visibility:
Public.

Description

[CSS Grid Layout] Fix issues adding new items to grid First if the grid auto flow property is different to none, the grid is marked as dirty when a new child is added. Because of if it contains auto-placed items, they might need to be re-positioned. Then if the new item has definite positions and auto flow is none, the grid will grow as required and place the new item without being marked as dirty. The test was not working properly, as it was adding the PASS messages as auto-placed grid items which was marking the grid as dirty and force a re-calculation of the position. Moving the results of the test to a different div make the test fails without this patch. Test expectation was updated accordingly. BUG=248151 TEST=fast/css-grid-layout/grid-item-addition-auto-placement-update.html Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=169784

Patch Set 1 #

Patch Set 2 : Simplify code of addChild() #

Total comments: 2

Patch Set 3 : Update growGrid() to grow several positions at a time #

Total comments: 2

Patch Set 4 : Keep else, improve comment and change param in growGrid() #

Unified diffs Side-by-side diffs Delta from patch set Stats (+35 lines, -22 lines) Patch
M LayoutTests/fast/css-grid-layout/grid-item-addition-auto-placement-update.html View 2 chunks +8 lines, -5 lines 0 comments Download
M LayoutTests/fast/css-grid-layout/grid-item-addition-auto-placement-update-expected.txt View 1 chunk +3 lines, -3 lines 0 comments Download
M Source/core/rendering/RenderGrid.h View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M Source/core/rendering/RenderGrid.cpp View 1 2 3 4 chunks +23 lines, -13 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
Manuel Rego
6 years, 9 months ago (2014-03-20 16:58:02 UTC) #1
Manuel Rego
Uploaded new version simplifying RenderGrid::addChild() code. Also improved the description of the code review.
6 years, 9 months ago (2014-03-20 17:10:09 UTC) #2
Julien - ping for review
lgtm. Some comments about the description: * typo: diffent in the first paragraph. * "The ...
6 years, 9 months ago (2014-03-21 04:10:35 UTC) #3
Manuel Rego
Thanks for the review. On 2014/03/21 04:10:35, Julien Chaffraix - PST wrote: > Some comments ...
6 years, 9 months ago (2014-03-21 11:26:48 UTC) #4
Julien - ping for review
> https://codereview.chromium.org/198703004/diff/20001/Source/core/rendering/RenderGrid.cpp#newcode206 > > Source/core/rendering/RenderGrid.cpp:206: return; > > Not sure what the return brings us ...
6 years, 9 months ago (2014-03-21 18:20:41 UTC) #5
Julien - ping for review
lgtm, I don't need to see the updated patch (unless you really want to me ...
6 years, 9 months ago (2014-03-21 18:27:18 UTC) #6
Manuel Rego
Applied suggested changes, thanks for the review.
6 years, 9 months ago (2014-03-22 00:04:57 UTC) #7
Manuel Rego
The CQ bit was checked by rego@igalia.com
6 years, 9 months ago (2014-03-22 00:05:05 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rego@igalia.com/198703004/60001
6 years, 9 months ago (2014-03-22 00:05:14 UTC) #9
commit-bot: I haz the power
6 years, 9 months ago (2014-03-22 04:27:59 UTC) #10
Message was sent while issue was closed.
Change committed as 169784

Powered by Google App Engine
This is Rietveld 408576698