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

Side by Side Diff: third_party/WebKit/Source/core/dom/Range.h

Issue 1854423002: ASSERT -> {DCHECK|DCHECK_XX}, ENABLE(ASSERT) -> DCHECK_IS_ON() in dom (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: mark svg/as-image/svg-nested.html crash on win 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 * (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 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv ed.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 class CORE_EXPORT Range final : public GarbageCollected<Range>, public ScriptWra ppable { 51 class CORE_EXPORT Range final : public GarbageCollected<Range>, public ScriptWra ppable {
52 DEFINE_WRAPPERTYPEINFO(); 52 DEFINE_WRAPPERTYPEINFO();
53 public: 53 public:
54 static RawPtr<Range> create(Document&); 54 static RawPtr<Range> create(Document&);
55 static RawPtr<Range> create(Document&, Node* startContainer, int startOffset , Node* endContainer, int endOffset); 55 static RawPtr<Range> create(Document&, Node* startContainer, int startOffset , Node* endContainer, int endOffset);
56 static RawPtr<Range> create(Document&, const Position&, const Position&); 56 static RawPtr<Range> create(Document&, const Position&, const Position&);
57 static RawPtr<Range> createAdjustedToTreeScope(const TreeScope&, const Posit ion&); 57 static RawPtr<Range> createAdjustedToTreeScope(const TreeScope&, const Posit ion&);
58 58
59 void dispose(); 59 void dispose();
60 60
61 Document& ownerDocument() const { ASSERT(m_ownerDocument); return *m_ownerDo cument.get(); } 61 Document& ownerDocument() const { DCHECK(m_ownerDocument); return *m_ownerDo cument.get(); }
62 Node* startContainer() const { return m_start.container(); } 62 Node* startContainer() const { return m_start.container(); }
63 int startOffset() const { return m_start.offset(); } 63 int startOffset() const { return m_start.offset(); }
64 Node* endContainer() const { return m_end.container(); } 64 Node* endContainer() const { return m_end.container(); }
65 int endOffset() const { return m_end.offset(); } 65 int endOffset() const { return m_end.offset(); }
66 66
67 bool collapsed() const { return m_start == m_end; } 67 bool collapsed() const { return m_start == m_end; }
68 bool inShadowIncludingDocument() const; 68 bool inShadowIncludingDocument() const;
69 69
70 Node* commonAncestorContainer() const; 70 Node* commonAncestorContainer() const;
71 static Node* commonAncestorContainer(const Node* containerA, const Node* con tainerB); 71 static Node* commonAncestorContainer(const Node* containerA, const Node* con tainerB);
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 CORE_EXPORT bool areRangesEqual(const Range*, const Range*); 173 CORE_EXPORT bool areRangesEqual(const Range*, const Range*);
174 174
175 } // namespace blink 175 } // namespace blink
176 176
177 #ifndef NDEBUG 177 #ifndef NDEBUG
178 // Outside the WebCore namespace for ease of invocation from gdb. 178 // Outside the WebCore namespace for ease of invocation from gdb.
179 void showTree(const blink::Range*); 179 void showTree(const blink::Range*);
180 #endif 180 #endif
181 181
182 #endif // Range_h 182 #endif // Range_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/QualifiedName.cpp ('k') | third_party/WebKit/Source/core/dom/Range.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698