Chromium Code Reviews
DescriptionMake ApplyStyleCommand::applyRelativeFontStyleChange() to handle AfterAnchor position correctly
This patch makes |ApplyStyleCommand::applyRelativeFontStyleChange()| to stop
node iteration from start position to end node position by using
|Position::nodeAsRangePastLastNode()| instead of |Position::anchorNode()| to
have correct beyond last node in below loop:
Node* beyondLast = end.anchorNode();
for (Node* node = startNode; node != beyondLast;
node = NodeTraversal::next(node)) {
... use |node| ...
}
When |end| is |AfterAnchor| of previous sibling of |startNode|, above loop
doesn't stop.
BUG=619753
TEST=LayoutTests/editing/execCommand/font-size-delta-after-anchor-crash.html
Committed: https://crrev.com/0117448155092540494f302397df47aa8c2bd421
Cr-Commit-Position: refs/heads/master@{#403750}
Patch Set 1 #Patch Set 2 : 2016-07-05T10:59:18 #
Total comments: 2
Messages
Total messages: 12 (4 generated)
|
||||||||||||||||||||||||||||