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

Side by Side Diff: sky/engine/core/rendering/RenderParagraph.cpp

Issue 944073006: Remove the concept of staticly positioned absolutes. (Closed) Base URL: git@github.com:domokit/mojo.git@position
Patch Set: Created 5 years, 10 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "sky/engine/config.h" 5 #include "sky/engine/config.h"
6 #include "sky/engine/core/rendering/RenderParagraph.h" 6 #include "sky/engine/core/rendering/RenderParagraph.h"
7 7
8 #include "sky/engine/core/rendering/BidiRunForLine.h" 8 #include "sky/engine/core/rendering/BidiRunForLine.h"
9 #include "sky/engine/core/rendering/InlineIterator.h" 9 #include "sky/engine/core/rendering/InlineIterator.h"
10 #include "sky/engine/core/rendering/RenderLayer.h" 10 #include "sky/engine/core/rendering/RenderLayer.h"
(...skipping 806 matching lines...) Expand 10 before | Expand all | Expand 10 after
817 817
818 RootInlineBox* lineBox = createLineBoxesFromBidiRuns(resolver.status ().context->level(), bidiRuns, endOfLine, layoutState.lineInfo(), verticalPositi onCache, trailingSpaceRun, wordMeasurements); 818 RootInlineBox* lineBox = createLineBoxesFromBidiRuns(resolver.status ().context->level(), bidiRuns, endOfLine, layoutState.lineInfo(), verticalPositi onCache, trailingSpaceRun, wordMeasurements);
819 819
820 bidiRuns.deleteRuns(); 820 bidiRuns.deleteRuns();
821 resolver.markCurrentRunEmpty(); // FIXME: This can probably be repla ced by an ASSERT (or just removed). 821 resolver.markCurrentRunEmpty(); // FIXME: This can probably be repla ced by an ASSERT (or just removed).
822 822
823 if (lineBox) 823 if (lineBox)
824 lineBox->setLineBreakInfo(endOfLine.object(), endOfLine.offset() , resolver.status()); 824 lineBox->setLineBreakInfo(endOfLine.object(), endOfLine.offset() , resolver.status());
825 } 825 }
826 826
827 for (size_t i = 0; i < lineBreaker.positionedObjects().size(); ++i)
828 setStaticPositions(this, lineBreaker.positionedObjects()[i]);
829
830 if (!layoutState.lineInfo().isEmpty()) 827 if (!layoutState.lineInfo().isEmpty())
831 layoutState.lineInfo().setFirstLine(false); 828 layoutState.lineInfo().setFirstLine(false);
832 829
833 lineMidpointState.reset(); 830 lineMidpointState.reset();
834 resolver.setPosition(endOfLine, numberOfIsolateAncestors(endOfLine)); 831 resolver.setPosition(endOfLine, numberOfIsolateAncestors(endOfLine));
835 } 832 }
836 } 833 }
837 834
838 void RenderParagraph::linkToEndLineIfNeeded(LineLayoutState& layoutState) 835 void RenderParagraph::linkToEndLineIfNeeded(LineLayoutState& layoutState)
839 { 836 {
(...skipping 744 matching lines...) Expand 10 before | Expand all | Expand 10 after
1584 curr->adjustLogicalPosition(logicalLeft, 0); 1581 curr->adjustLogicalPosition(logicalLeft, 0);
1585 else 1582 else
1586 curr->adjustLogicalPosition(logicalLeft - (availableLogicalW idth - totalLogicalWidth), 0); 1583 curr->adjustLogicalPosition(logicalLeft - (availableLogicalW idth - totalLogicalWidth), 0);
1587 } 1584 }
1588 } 1585 }
1589 firstLine = false; 1586 firstLine = false;
1590 } 1587 }
1591 } 1588 }
1592 1589
1593 } // namespace blink 1590 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698