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

Side by Side Diff: Source/core/dom/Range.cpp

Issue 422463002: Hide isXXX() type checking methods in subclasses (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/dom/Element.h ('k') | Source/core/dom/Text.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * (C) 1999 Lars Knoll (knoll@kde.org) 2 * (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Gunnstein Lye (gunnstein@netcom.no) 3 * (C) 2000 Gunnstein Lye (gunnstein@netcom.no)
4 * (C) 2000 Frederik Holljen (frederik.holljen@hig.no) 4 * (C) 2000 Frederik Holljen (frederik.holljen@hig.no)
5 * (C) 2001 Peter Kelly (pmk@post.com) 5 * (C) 2001 Peter Kelly (pmk@post.com)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
7 * Copyright (C) 2011 Motorola Mobility. All rights reserved. 7 * Copyright (C) 2011 Motorola Mobility. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 1573 matching lines...) Expand 10 before | Expand all | Expand 10 after
1584 if (boundary.childBefore() == &oldNode) 1584 if (boundary.childBefore() == &oldNode)
1585 boundary.set(boundaryContainer, boundaryOffset + 1, oldNode.nextSibling( )); 1585 boundary.set(boundaryContainer, boundaryOffset + 1, oldNode.nextSibling( ));
1586 else if (boundary.container() == &oldNode && boundaryOffset > oldNode.length ()) 1586 else if (boundary.container() == &oldNode && boundaryOffset > oldNode.length ())
1587 boundary.set(oldNode.nextSibling(), boundaryOffset - oldNode.length(), 0 ); 1587 boundary.set(oldNode.nextSibling(), boundaryOffset - oldNode.length(), 0 );
1588 } 1588 }
1589 1589
1590 void Range::didSplitTextNode(Text& oldNode) 1590 void Range::didSplitTextNode(Text& oldNode)
1591 { 1591 {
1592 ASSERT(oldNode.document() == m_ownerDocument); 1592 ASSERT(oldNode.document() == m_ownerDocument);
1593 ASSERT(oldNode.parentNode()); 1593 ASSERT(oldNode.parentNode());
1594 ASSERT(oldNode.isTextNode());
1595 ASSERT(oldNode.nextSibling()); 1594 ASSERT(oldNode.nextSibling());
1596 ASSERT(oldNode.nextSibling()->isTextNode()); 1595 ASSERT(oldNode.nextSibling()->isTextNode());
1597 boundaryTextNodeSplit(m_start, oldNode); 1596 boundaryTextNodeSplit(m_start, oldNode);
1598 boundaryTextNodeSplit(m_end, oldNode); 1597 boundaryTextNodeSplit(m_end, oldNode);
1599 ASSERT(boundaryPointsValid()); 1598 ASSERT(boundaryPointsValid());
1600 } 1599 }
1601 1600
1602 void Range::expand(const String& unit, ExceptionState& exceptionState) 1601 void Range::expand(const String& unit, ExceptionState& exceptionState)
1603 { 1602 {
1604 VisiblePosition start(startPosition()); 1603 VisiblePosition start(startPosition());
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
1704 1703
1705 void showTree(const blink::Range* range) 1704 void showTree(const blink::Range* range)
1706 { 1705 {
1707 if (range && range->boundaryPointsValid()) { 1706 if (range && range->boundaryPointsValid()) {
1708 range->startContainer()->showTreeAndMark(range->startContainer(), "S", r ange->endContainer(), "E"); 1707 range->startContainer()->showTreeAndMark(range->startContainer(), "S", r ange->endContainer(), "E");
1709 fprintf(stderr, "start offset: %d, end offset: %d\n", range->startOffset (), range->endOffset()); 1708 fprintf(stderr, "start offset: %d, end offset: %d\n", range->startOffset (), range->endOffset());
1710 } 1709 }
1711 } 1710 }
1712 1711
1713 #endif 1712 #endif
OLDNEW
« no previous file with comments | « Source/core/dom/Element.h ('k') | Source/core/dom/Text.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698