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

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

Issue 225303002: Let Selection.collapse remember a raw Position instead of a canonicalized one. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix setSelectedRange arguments Created 6 years, 6 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/core/editing/FrameSelection.cpp
diff --git a/Source/core/editing/FrameSelection.cpp b/Source/core/editing/FrameSelection.cpp
index 4e72e8c317979864b9730bbc34459d17d35e6c9f..4f53aba0f442dbbe2b6d9de79290c216724638dd 100644
--- a/Source/core/editing/FrameSelection.cpp
+++ b/Source/core/editing/FrameSelection.cpp
@@ -1403,7 +1403,7 @@ void FrameSelection::selectAll()
notifyRendererOfSelectionChange(UserTriggered);
}
-bool FrameSelection::setSelectedRange(Range* range, EAffinity affinity, SetSelectionOptions options)
+bool FrameSelection::setSelectedRange(Range* range, EAffinity affinity, bool isDirectional, SetSelectionOptions options)
{
if (!range || !range->startContainer() || !range->endContainer())
return false;
@@ -1414,7 +1414,7 @@ bool FrameSelection::setSelectedRange(Range* range, EAffinity affinity, SetSelec
m_logicalRange = nullptr;
stopObservingVisibleSelectionChangeIfNecessary();
- VisibleSelection newSelection(range, affinity);
+ VisibleSelection newSelection(range, affinity, isDirectional);
setSelection(newSelection, options);
m_logicalRange = range->cloneRange();

Powered by Google App Engine
This is Rietveld 408576698