| Index: third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
|
| diff --git a/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp b/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
|
| index 086a79881696112c584d0d849db0724672006d89..242f27e5068c93412ca97a63a7301fa13d1c9990 100644
|
| --- a/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
|
| +++ b/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
|
| @@ -1360,6 +1360,16 @@ void WebLocalFrameImpl::setCaretVisible(bool visible)
|
| frame()->selection().setCaretVisible(visible);
|
| }
|
|
|
| +void WebLocalFrameImpl::clearFocus()
|
| +{
|
| + if (!frame()->page())
|
| + return;
|
| +
|
| + // This uses setFocusedElement rather than setFocusedFrame so that blur
|
| + // events are properly dispatched on any currently focused elements.
|
| + frame()->page()->focusController().setFocusedElement(nullptr, nullptr);
|
| +}
|
| +
|
| VisiblePosition WebLocalFrameImpl::visiblePositionForViewportPoint(const WebPoint& pointInViewport)
|
| {
|
| return visiblePositionForContentsPoint(frame()->view()->viewportToContents(pointInViewport), frame());
|
|
|