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

Unified Diff: Source/WebCore/editing/BreakBlockquoteCommand.cpp

Issue 13954003: Remove mail blockquote special case handling. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 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
Index: Source/WebCore/editing/BreakBlockquoteCommand.cpp
diff --git a/Source/WebCore/editing/BreakBlockquoteCommand.cpp b/Source/WebCore/editing/BreakBlockquoteCommand.cpp
index e4ee4c389d40ecc1842b1cdf9b6a3601deda20a8..86eaf09329f6a6cc2a9bf7fad0044275d56e8e96 100644
--- a/Source/WebCore/editing/BreakBlockquoteCommand.cpp
+++ b/Source/WebCore/editing/BreakBlockquoteCommand.cpp
@@ -66,11 +66,6 @@ void BreakBlockquoteCommand::doApply()
// be in the first node that we need to move (there are a few exceptions to this, see below).
Position pos = endingSelection().start().downstream();
- // Find the top-most blockquote from the start.
- Node* topBlockquote = highestEnclosingNodeOfType(pos, isMailBlockquote);
- if (!topBlockquote || !topBlockquote->parentNode() || !topBlockquote->isElementNode())
- return;
-
RefPtr<Element> breakNode = createBreakElement(document());
bool isLastVisPosInNode = isLastVisiblePositionInNode(visiblePos, topBlockquote);
@@ -99,10 +94,6 @@ void BreakBlockquoteCommand::doApply()
if (lineBreakExistsAtVisiblePosition(visiblePos))
pos = pos.next();
- // Adjust the position so we don't split at the beginning of a quote.
- while (isFirstVisiblePositionInNode(VisiblePosition(pos), enclosingNodeOfType(pos, isMailBlockquote)))
- pos = pos.previous();
-
// startNode is the first node that we need to move to the new blockquote.
Node* startNode = pos.deprecatedNode();

Powered by Google App Engine
This is Rietveld 408576698