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

Unified Diff: third_party/WebKit/Source/core/editing/commands/EditCommand.cpp

Issue 2450213002: Utilize EditCommand::setEndingSelection() taking SelectionInDOMTree (Closed)
Patch Set: 2016-10-28T14:44:14 Created 4 years, 2 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: third_party/WebKit/Source/core/editing/commands/EditCommand.cpp
diff --git a/third_party/WebKit/Source/core/editing/commands/EditCommand.cpp b/third_party/WebKit/Source/core/editing/commands/EditCommand.cpp
index 7cf80e0d7ea311cb5d4ae85d82de0ac717e5771c..b82246f8baca4f99f584706f4ba0b1616cb9864d 100644
--- a/third_party/WebKit/Source/core/editing/commands/EditCommand.cpp
+++ b/third_party/WebKit/Source/core/editing/commands/EditCommand.cpp
@@ -39,7 +39,7 @@ EditCommand::EditCommand(Document& document)
DCHECK(m_document);
DCHECK(m_document->frame());
setStartingSelection(m_document->frame()->selection().selection());
- setEndingSelection(m_startingSelection);
+ setEndingVisibleSelection(m_startingSelection);
}
EditCommand::~EditCommand() {}
@@ -79,12 +79,12 @@ void EditCommand::setEndingSelection(const SelectionInDOMTree& selection) {
// updateStyleAndLayoutIgnorePendingStylesheets
// needs to be audited. See http://crbug.com/590369 for more details.
document().updateStyleAndLayoutIgnorePendingStylesheets();
- setEndingSelection(createVisibleSelection(selection));
+ setEndingVisibleSelection(createVisibleSelection(selection));
}
// TODO(yosin): We will make |SelectionInDOMTree| version of
// |setEndingSelection()| as primary function instead of wrapper.
-void EditCommand::setEndingSelection(const VisibleSelection& selection) {
+void EditCommand::setEndingVisibleSelection(const VisibleSelection& selection) {
for (EditCommand* command = this; command; command = command->m_parent) {
if (EditCommandComposition* composition = compositionIfPossible(command)) {
DCHECK(command->isTopLevelCommand());

Powered by Google App Engine
This is Rietveld 408576698