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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutFlexibleBox.h

Issue 1875263005: [css-flexbox] More correctly implement percentage sizing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 void alignChildren(const Vector<LineContext>&); 185 void alignChildren(const Vector<LineContext>&);
186 void applyStretchAlignmentToChild(LayoutBox& child, LayoutUnit lineCrossAxis Extent); 186 void applyStretchAlignmentToChild(LayoutBox& child, LayoutUnit lineCrossAxis Extent);
187 void flipForRightToLeftColumn(); 187 void flipForRightToLeftColumn();
188 void flipForWrapReverse(const Vector<LineContext>&, LayoutUnit crossAxisStar tEdge); 188 void flipForWrapReverse(const Vector<LineContext>&, LayoutUnit crossAxisStar tEdge);
189 189
190 float countIntrinsicSizeForAlgorithmChange(LayoutUnit maxPreferredWidth, Lay outBox* child, float previousMaxContentFlexFraction) const; 190 float countIntrinsicSizeForAlgorithmChange(LayoutUnit maxPreferredWidth, Lay outBox* child, float previousMaxContentFlexFraction) const;
191 191
192 // This is used to cache the preferred size for orthogonal flow children so we don't have to relayout to get it 192 // This is used to cache the preferred size for orthogonal flow children so we don't have to relayout to get it
193 HashMap<const LayoutObject*, LayoutUnit> m_intrinsicSizeAlongMainAxis; 193 HashMap<const LayoutObject*, LayoutUnit> m_intrinsicSizeAlongMainAxis;
194 194
195 // This set is used to keep track of which children we laid out in this curr ent layout iteration.
196 // We need it because the ones in this set may need an additional layout pas s for correct stretch alignment
197 // handling, as the first layout likely did not use the correct value for pe rcentage sizing of children.
198 HashSet<const LayoutObject*> m_relaidOutChildren;
199
195 mutable OrderIterator m_orderIterator; 200 mutable OrderIterator m_orderIterator;
196 int m_numberOfInFlowChildrenOnFirstLine; 201 int m_numberOfInFlowChildrenOnFirstLine;
197 }; 202 };
198 203
199 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutFlexibleBox, isFlexibleBox()); 204 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutFlexibleBox, isFlexibleBox());
200 205
201 } // namespace blink 206 } // namespace blink
202 207
203 #endif // LayoutFlexibleBox_h 208 #endif // LayoutFlexibleBox_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698