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

Unified Diff: Source/core/dom/Range.h

Issue 252783002: Make Range.detach() a no-op (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/fast/dom/Range/resources/intersectsNode.js ('k') | Source/core/dom/Range.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Range.h
diff --git a/Source/core/dom/Range.h b/Source/core/dom/Range.h
index a217857e6de1908458c2343f8661c4e90f60dc2d..1234f34ec57afdeb8e095bfc38abaf7577f7f01b 100644
--- a/Source/core/dom/Range.h
+++ b/Source/core/dom/Range.h
@@ -61,17 +61,13 @@ public:
Node* endContainer() const { return m_end.container(); }
int endOffset() const { return m_end.offset(); }
- Node* startContainer(ExceptionState&) const;
- int startOffset(ExceptionState&) const;
- Node* endContainer(ExceptionState&) const;
- int endOffset(ExceptionState&) const;
- bool collapsed(ExceptionState&) const;
+ bool collapsed() const { return m_start == m_end; }
- Node* commonAncestorContainer(ExceptionState&) const;
+ Node* commonAncestorContainer() const;
static Node* commonAncestorContainer(Node* containerA, Node* containerB);
void setStart(PassRefPtr<Node> container, int offset, ExceptionState& = ASSERT_NO_EXCEPTION);
void setEnd(PassRefPtr<Node> container, int offset, ExceptionState& = ASSERT_NO_EXCEPTION);
- void collapse(bool toStart, ExceptionState&);
+ void collapse(bool toStart);
bool isPointInRange(Node* refNode, int offset, ExceptionState&);
short comparePoint(Node* refNode, int offset, ExceptionState&) const;
enum CompareResults { NODE_BEFORE, NODE_AFTER, NODE_BEFORE_AND_AFTER, NODE_INSIDE };
@@ -86,15 +82,15 @@ public:
PassRefPtr<DocumentFragment> extractContents(ExceptionState&);
PassRefPtr<DocumentFragment> cloneContents(ExceptionState&);
void insertNode(PassRefPtr<Node>, ExceptionState&);
- String toString(ExceptionState&) const;
+ String toString() const;
String toHTML() const;
String text() const;
PassRefPtr<DocumentFragment> createContextualFragment(const String& html, ExceptionState&);
- void detach(ExceptionState&);
- PassRefPtrWillBeRawPtr<Range> cloneRange(ExceptionState&) const;
+ void detach();
+ PassRefPtrWillBeRawPtr<Range> cloneRange() const;
void setStartAfter(Node*, ExceptionState& = ASSERT_NO_EXCEPTION);
void setEndBefore(Node*, ExceptionState& = ASSERT_NO_EXCEPTION);
« no previous file with comments | « LayoutTests/fast/dom/Range/resources/intersectsNode.js ('k') | Source/core/dom/Range.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698