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

Unified Diff: Source/core/layout/LayoutGrid.h

Issue 1125703002: [CSS Grid Layout] Refactoring of grid's alignment logic (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/core/layout/LayoutGrid.cpp » ('j') | Source/core/layout/LayoutGrid.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutGrid.h
diff --git a/Source/core/layout/LayoutGrid.h b/Source/core/layout/LayoutGrid.h
index e26f163760f510b3d58ffb310747f1ac82081d33..6328f08b48171399bf2e875dc364dffa98c7e6ad 100644
--- a/Source/core/layout/LayoutGrid.h
+++ b/Source/core/layout/LayoutGrid.h
@@ -37,6 +37,8 @@ struct GridSpan;
class GridTrack;
class GridItemWithSpan;
+enum GridAxisPosition {GridAxisStart, GridAxisEnd, GridAxisCenter};
+
class LayoutGrid final : public LayoutBlock {
public:
LayoutGrid(Element*);
@@ -114,15 +116,9 @@ private:
LayoutUnit logicalHeightForChild(LayoutBox&, Vector<GridTrack>&);
LayoutUnit minContentForChild(LayoutBox&, GridTrackSizingDirection, Vector<GridTrack>& columnTracks);
LayoutUnit maxContentForChild(LayoutBox&, GridTrackSizingDirection, Vector<GridTrack>& columnTracks);
- LayoutUnit startOfColumnForChild(const LayoutBox& child) const;
- LayoutUnit endOfColumnForChild(const LayoutBox& child) const;
- LayoutUnit columnPositionLeft(const LayoutBox&) const;
- LayoutUnit columnPositionRight(const LayoutBox&) const;
- LayoutUnit centeredColumnPositionForChild(const LayoutBox&) const;
+ GridAxisPosition columnAxisPositionForChild(const LayoutBox&) const;
+ GridAxisPosition rowAxisPositionForChild(const LayoutBox&) const;
LayoutUnit columnPositionForChild(const LayoutBox&) const;
- LayoutUnit startOfRowForChild(const LayoutBox& child) const;
- LayoutUnit endOfRowForChild(const LayoutBox& child) const;
- LayoutUnit centeredRowPositionForChild(const LayoutBox&) const;
LayoutUnit rowPositionForChild(const LayoutBox&) const;
void computeContentPositionAndDistributionRowOffset(LayoutUnit availableFreeSpace, GridSizingData&) const;
void computeContentPositionAndDistributionColumnOffset(LayoutUnit availableFreeSpace, GridSizingData&) const;
« no previous file with comments | « no previous file | Source/core/layout/LayoutGrid.cpp » ('j') | Source/core/layout/LayoutGrid.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698