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

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

Issue 1870663002: Reland main thread position sticky implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Only descend into children which have an ancestor overflow layer. 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 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 layoutPositionedObjects(relayoutChildren || isDocumentElement()); 302 layoutPositionedObjects(relayoutChildren || isDocumentElement());
303 303
304 // FIXME: css3/flexbox/repaint-rtl-column.html seems to issue paint inva lidations for more overflow than it needs to. 304 // FIXME: css3/flexbox/repaint-rtl-column.html seems to issue paint inva lidations for more overflow than it needs to.
305 computeOverflow(clientLogicalBottomAfterRepositioning()); 305 computeOverflow(clientLogicalBottomAfterRepositioning());
306 } 306 }
307 307
308 updateLayerTransformAfterLayout(); 308 updateLayerTransformAfterLayout();
309 309
310 // Update our scroll information if we're overflow:auto/scroll/hidden now th at we know if 310 // Update our scroll information if we're overflow:auto/scroll/hidden now th at we know if
311 // we overflow or not. 311 // we overflow or not.
312 updateScrollInfoAfterLayout(); 312 updateAfterLayout();
313 313
314 clearNeedsLayout(); 314 clearNeedsLayout();
315 } 315 }
316 316
317 void LayoutFlexibleBox::paintChildren(const PaintInfo& paintInfo, const LayoutPo int& paintOffset) const 317 void LayoutFlexibleBox::paintChildren(const PaintInfo& paintInfo, const LayoutPo int& paintOffset) const
318 { 318 {
319 BlockPainter::paintChildrenOfFlexibleBox(*this, paintInfo, paintOffset); 319 BlockPainter::paintChildrenOfFlexibleBox(*this, paintInfo, paintOffset);
320 } 320 }
321 321
322 void LayoutFlexibleBox::repositionLogicalHeightDependentFlexItems(Vector<LineCon text>& lineContexts) 322 void LayoutFlexibleBox::repositionLogicalHeightDependentFlexItems(Vector<LineCon text>& lineContexts)
(...skipping 1455 matching lines...) Expand 10 before | Expand all | Expand 10 after
1778 ASSERT(child); 1778 ASSERT(child);
1779 LayoutUnit lineCrossAxisExtent = lineContexts[lineNumber].crossAxisE xtent; 1779 LayoutUnit lineCrossAxisExtent = lineContexts[lineNumber].crossAxisE xtent;
1780 LayoutUnit originalOffset = lineContexts[lineNumber].crossAxisOffset - crossAxisStartEdge; 1780 LayoutUnit originalOffset = lineContexts[lineNumber].crossAxisOffset - crossAxisStartEdge;
1781 LayoutUnit newOffset = contentExtent - originalOffset - lineCrossAxi sExtent; 1781 LayoutUnit newOffset = contentExtent - originalOffset - lineCrossAxi sExtent;
1782 adjustAlignmentForChild(*child, newOffset - originalOffset); 1782 adjustAlignmentForChild(*child, newOffset - originalOffset);
1783 } 1783 }
1784 } 1784 }
1785 } 1785 }
1786 1786
1787 } // namespace blink 1787 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698