| Index: third_party/WebKit/Source/core/testing/Internals.cpp
|
| diff --git a/third_party/WebKit/Source/core/testing/Internals.cpp b/third_party/WebKit/Source/core/testing/Internals.cpp
|
| index 3b798ec93b6e4f0519db810ffddef6c3e5ec2560..213876fb6141745371e6f8045905d012e2f5538b 100644
|
| --- a/third_party/WebKit/Source/core/testing/Internals.cpp
|
| +++ b/third_party/WebKit/Source/core/testing/Internals.cpp
|
| @@ -2607,6 +2607,34 @@ void Internals::forceReload(bool bypassCache) {
|
| ClientRedirectPolicy::NotClientRedirect);
|
| }
|
|
|
| +Node* Internals::visibleSelectionAnchorNode() {
|
| + if (!frame())
|
| + return nullptr;
|
| + Position position = frame()->selection().base();
|
| + return position.isNull() ? nullptr : position.computeContainerNode();
|
| +}
|
| +
|
| +unsigned Internals::visibleSelectionAnchorOffset() {
|
| + if (!frame())
|
| + return 0;
|
| + Position position = frame()->selection().base();
|
| + return position.isNull() ? 0 : position.computeOffsetInContainerNode();
|
| +}
|
| +
|
| +Node* Internals::visibleSelectionFocusNode() {
|
| + if (!frame())
|
| + return nullptr;
|
| + Position position = frame()->selection().extent();
|
| + return position.isNull() ? nullptr : position.computeContainerNode();
|
| +}
|
| +
|
| +unsigned Internals::visibleSelectionFocusOffset() {
|
| + if (!frame())
|
| + return 0;
|
| + Position position = frame()->selection().extent();
|
| + return position.isNull() ? 0 : position.computeOffsetInContainerNode();
|
| +}
|
| +
|
| ClientRect* Internals::selectionBounds(ExceptionState& exceptionState) {
|
| if (!frame()) {
|
| exceptionState.throwDOMException(
|
|
|