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

Unified Diff: third_party/WebKit/Source/core/editing/EditingUtilities.cpp

Issue 2374183004: Make non-null VisibleSelections creatable only by createVisibleSelection[Deprecated] (Closed)
Patch Set: Fix mac compile error Created 4 years, 3 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/EditingUtilities.cpp
diff --git a/third_party/WebKit/Source/core/editing/EditingUtilities.cpp b/third_party/WebKit/Source/core/editing/EditingUtilities.cpp
index 0fc510b13514452c620815b0f197b1e2ee940a49..b807bfd9772dc4eca16002d5009d829a1317af50 100644
--- a/third_party/WebKit/Source/core/editing/EditingUtilities.cpp
+++ b/third_party/WebKit/Source/core/editing/EditingUtilities.cpp
@@ -1684,7 +1684,7 @@ VisibleSelection selectionForParagraphIteration(const VisibleSelection& original
// (a table is itself a paragraph).
if (Element* table = tableElementJustBefore(endOfSelection)) {
if (startOfSelection.deepEquivalent().anchorNode()->isDescendantOf(table))
- newSelection = VisibleSelection(startOfSelection, previousPositionOf(endOfSelection, CannotCrossEditingBoundary));
+ newSelection = createVisibleSelectionDeprecated(startOfSelection, previousPositionOf(endOfSelection, CannotCrossEditingBoundary));
}
// If the start of the selection to modify is just before a table,
@@ -1693,7 +1693,7 @@ VisibleSelection selectionForParagraphIteration(const VisibleSelection& original
// containing the table itself.
if (Element* table = tableElementJustAfter(startOfSelection)) {
if (endOfSelection.deepEquivalent().anchorNode()->isDescendantOf(table))
- newSelection = VisibleSelection(nextPositionOf(startOfSelection, CannotCrossEditingBoundary), endOfSelection);
+ newSelection = createVisibleSelectionDeprecated(nextPositionOf(startOfSelection, CannotCrossEditingBoundary), endOfSelection);
}
return newSelection;

Powered by Google App Engine
This is Rietveld 408576698