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

Unified Diff: Source/core/editing/markup.cpp

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 | « Source/core/editing/TextIteratorTest.cpp ('k') | Source/core/frame/UseCounter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/editing/markup.cpp
diff --git a/Source/core/editing/markup.cpp b/Source/core/editing/markup.cpp
index 5e3d19fae39410014d618651848f43a27b74d965..b70316d1b23d8f95a1c390bd4da341e635c78442 100644
--- a/Source/core/editing/markup.cpp
+++ b/Source/core/editing/markup.cpp
@@ -496,7 +496,7 @@ static bool isElementPresentational(const Node* node)
static Node* highestAncestorToWrapMarkup(const Range* range, EAnnotateForInterchange shouldAnnotate, Node* constrainingAncestor)
{
- Node* commonAncestor = range->commonAncestorContainer(IGNORE_EXCEPTION);
+ Node* commonAncestor = range->commonAncestorContainer();
ASSERT(commonAncestor);
Node* specialCommonAncestor = 0;
if (shouldAnnotate == AnnotateForInterchange) {
@@ -548,10 +548,10 @@ static String createMarkupInternal(Document& document, const Range* range, const
ASSERT(updatedRange);
DEFINE_STATIC_LOCAL(const String, interchangeNewlineString, ("<br class=\"" AppleInterchangeNewline "\">"));
- bool collapsed = updatedRange->collapsed(ASSERT_NO_EXCEPTION);
+ bool collapsed = updatedRange->collapsed();
if (collapsed)
return emptyString();
- Node* commonAncestor = updatedRange->commonAncestorContainer(ASSERT_NO_EXCEPTION);
+ Node* commonAncestor = updatedRange->commonAncestorContainer();
if (!commonAncestor)
return emptyString();
@@ -717,7 +717,7 @@ PassRefPtr<DocumentFragment> createFragmentFromMarkupWithContext(Document& docum
positionAfterNode(nodeBeforeContext.get()).parentAnchoredEquivalent(),
positionBeforeNode(nodeAfterContext.get()).parentAnchoredEquivalent());
- Node* commonAncestor = range->commonAncestorContainer(ASSERT_NO_EXCEPTION);
+ Node* commonAncestor = range->commonAncestorContainer();
Node* specialCommonAncestor = ancestorToRetainStructureAndAppearanceWithNoRenderer(commonAncestor);
// When there's a special common ancestor outside of the fragment, we must include it as well to
« no previous file with comments | « Source/core/editing/TextIteratorTest.cpp ('k') | Source/core/frame/UseCounter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698