Chromium Code Reviews| Index: third_party/WebKit/Source/web/ChromeClientImpl.cpp |
| diff --git a/third_party/WebKit/Source/web/ChromeClientImpl.cpp b/third_party/WebKit/Source/web/ChromeClientImpl.cpp |
| index 1c2e7784d2bde4cddf3a0c06d41c1d99231a2e2a..81074b2ea4c02229431b87e1df393e365b0fe6fd 100644 |
| --- a/third_party/WebKit/Source/web/ChromeClientImpl.cpp |
| +++ b/third_party/WebKit/Source/web/ChromeClientImpl.cpp |
| @@ -825,14 +825,28 @@ void ChromeClientImpl::exitFullScreenForElement(Element* element) |
| m_webView->exitFullScreenForElement(element); |
| } |
| -void ChromeClientImpl::clearCompositedSelection() |
| +void ChromeClientImpl::clearCompositedSelection(LocalFrame* frame) |
| { |
| - m_webView->clearCompositedSelection(); |
| + LocalFrame* localRoot = frame->localFrameRoot(); |
| + auto client = WebLocalFrameImpl::fromFrame(localRoot)->frameWidget()->client(); |
|
bokan
2016/08/11 14:14:06
I don't think `auto` helps in these cases. My read
wjmaclean
2016/08/11 14:35:06
Done.
|
| + if (!client) |
| + return; |
| + |
| + auto layerTreeView = client->layerTreeView(); |
| + if (layerTreeView) |
| + layerTreeView->clearSelection(); |
| } |
| -void ChromeClientImpl::updateCompositedSelection(const CompositedSelection& selection) |
| +void ChromeClientImpl::updateCompositedSelection(LocalFrame* frame, const CompositedSelection& selection) |
| { |
| - m_webView->updateCompositedSelection(WebSelection(selection)); |
| + LocalFrame* localRoot = frame->localFrameRoot(); |
| + auto client = WebLocalFrameImpl::fromFrame(localRoot)->frameWidget()->client(); |
| + if (!client) |
| + return; |
| + |
| + auto layerTreeView = client->layerTreeView(); |
| + if (layerTreeView) |
| + layerTreeView->registerSelection(WebSelection(selection)); |
| } |
| bool ChromeClientImpl::hasOpenedPopup() const |