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

Issue 2526383004: [css-grid] Cleanup LayoutGrid::Grid (Closed)

Created:
4 years ago by svillar
Modified:
4 years ago
CC:
chromium-reviews, jfernandez, szager+layoutwatch_chromium.org, zoltan1, blink-reviews-layout_chromium.org, pdr+renderingwatchlist_chromium.org, Manuel Rego, leviw+renderwatch, jchaffraix+rendering, blink-reviews, eae+blinkwatch
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[css-grid] Cleanup LayoutGrid::Grid This is a cleanup of some recent additions to the Grid class, basically some renames and an API change. The hasInFlowGridItems was renamed to hasGridItems because by definition all grid items are in flow children of the grid container. Apart from that, in order to remove an extra attribute for the Grid::insert method, a new method called setHasAnyOrthogonalGridItem was added to track the existence of orthogonal items. BUG=627812 Committed: https://crrev.com/9b31974d98b5e1c03990d68129e6debca1e37cd6 Cr-Commit-Position: refs/heads/master@{#434641}

Patch Set 1 #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+32 lines, -23 lines) Patch
M third_party/WebKit/Source/core/layout/LayoutGrid.h View 2 chunks +9 lines, -4 lines 3 comments Download
M third_party/WebKit/Source/core/layout/LayoutGrid.cpp View 14 chunks +23 lines, -19 lines 0 comments Download

Messages

Total messages: 12 (4 generated)
svillar
4 years ago (2016-11-25 18:16:09 UTC) #2
Manuel Rego
lgtm https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/core/layout/LayoutGrid.h File third_party/WebKit/Source/core/layout/LayoutGrid.h (right): https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/core/layout/LayoutGrid.h#newcode351 third_party/WebKit/Source/core/layout/LayoutGrid.h:351: bool hasGridItems() const { return !m_gridItemArea.isEmpty(); } Nit: ...
4 years ago (2016-11-25 18:23:25 UTC) #3
svillar
https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/core/layout/LayoutGrid.h File third_party/WebKit/Source/core/layout/LayoutGrid.h (right): https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/core/layout/LayoutGrid.h#newcode351 third_party/WebKit/Source/core/layout/LayoutGrid.h:351: bool hasGridItems() const { return !m_gridItemArea.isEmpty(); } On 2016/11/25 ...
4 years ago (2016-11-28 11:21:25 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2526383004/1
4 years ago (2016-11-28 11:21:40 UTC) #6
Manuel Rego
https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/core/layout/LayoutGrid.h File third_party/WebKit/Source/core/layout/LayoutGrid.h (right): https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/core/layout/LayoutGrid.h#newcode351 third_party/WebKit/Source/core/layout/LayoutGrid.h:351: bool hasGridItems() const { return !m_gridItemArea.isEmpty(); } On 2016/11/28 ...
4 years ago (2016-11-28 11:46:04 UTC) #7
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years ago (2016-11-28 12:35:58 UTC) #9
commit-bot: I haz the power
Patchset 1 (id:??) landed as https://crrev.com/9b31974d98b5e1c03990d68129e6debca1e37cd6 Cr-Commit-Position: refs/heads/master@{#434641}
4 years ago (2016-11-28 12:37:24 UTC) #11
svillar
4 years ago (2016-11-28 14:36:53 UTC) #12
Message was sent while issue was closed.
On 2016/11/28 11:46:04, Manuel Rego wrote:
>
https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/c...
> File third_party/WebKit/Source/core/layout/LayoutGrid.h (right):
> 
>
https://codereview.chromium.org/2526383004/diff/1/third_party/WebKit/Source/c...
> third_party/WebKit/Source/core/layout/LayoutGrid.h:351: bool hasGridItems()
> const { return !m_gridItemArea.isEmpty(); }
> On 2016/11/28 11:21:25, svillar wrote:
> > On 2016/11/25 18:23:25, Manuel Rego wrote:
> > > Nit: Maybe we could have a isEmpty() method. Not 100% sure
> > > as it might be confusing due to the out-of-flow
> > > and in-flow children.
> > 
> > I don't think we need that. We could always check the existence of children
> > using the LayoutBox methods.
> 
> It's clear I choose a bad name, I was thinking in:
>   bool isEmpty() const { return m_gridItemArea.isEmpty(); }

So the thing is that m_gridItemArea is a very specific implementation detail of
Grid. I don't think we should expose it too much.

Powered by Google App Engine
This is Rietveld 408576698