| Index: Source/core/editing/EditingUtilities.cpp
|
| diff --git a/Source/core/editing/EditingUtilities.cpp b/Source/core/editing/EditingUtilities.cpp
|
| index 7a7148bb41ca301b61ed411a042b07df4d6b93d5..e4905bc2ba6ab45b1d818a00417704bde1528289 100644
|
| --- a/Source/core/editing/EditingUtilities.cpp
|
| +++ b/Source/core/editing/EditingUtilities.cpp
|
| @@ -1511,6 +1511,19 @@ int indexForVisiblePosition(const VisiblePosition& visiblePosition, RefPtrWillBe
|
| return TextIterator::rangeLength(range->startPosition(), range->endPosition(), true);
|
| }
|
|
|
| +EphemeralRange makeRange(const VisiblePosition &start, const VisiblePosition &end)
|
| +{
|
| + if (start.isNull() || end.isNull())
|
| + return EphemeralRange();
|
| +
|
| + Position s = start.deepEquivalent().parentAnchoredEquivalent();
|
| + Position e = end.deepEquivalent().parentAnchoredEquivalent();
|
| + if (s.isNull() || e.isNull())
|
| + return EphemeralRange();
|
| +
|
| + return EphemeralRange(s, e);
|
| +}
|
| +
|
| VisiblePosition visiblePositionForIndex(int index, ContainerNode* scope)
|
| {
|
| if (!scope)
|
|
|