Chromium Code Reviews| Index: Source/web/WebViewImpl.cpp |
| diff --git a/Source/web/WebViewImpl.cpp b/Source/web/WebViewImpl.cpp |
| index 3209b7da59060cf7058ce836b96ed9277f365b4c..09212866013f50832e8aadf1db4c46d9b6687f8b 100644 |
| --- a/Source/web/WebViewImpl.cpp |
| +++ b/Source/web/WebViewImpl.cpp |
| @@ -3373,6 +3373,19 @@ void WebViewImpl::spellingMarkers(WebVector<uint32_t>* markers) |
| markers->assign(result); |
| } |
| +void WebViewImpl::removeSpellingMarkersUnderWords(const WebVector<WebString>& words) |
| +{ |
| + for (Frame* frame = m_page->mainFrame(); frame; frame = frame->tree().traverseNext()) { |
| + if (!frame->isLocalFrame()) |
| + continue; |
| + |
| + LocalFrame* localFrame = static_cast<LocalFrame*>(frame); |
|
dcheng
2014/08/14 17:34:28
Please use toLocalFrame() instead of static_cast<L
|
| + WebLocalFrameImpl* webLocalFrame = |
| + WebLocalFrameImpl::fromFrame(localFrame); |
|
tkent
2014/08/14 01:17:15
You don't need to wrap this code.
Klemen Forstnerič
2014/08/14 16:42:54
I don't understand this comment. Could you please
dcheng
2014/08/14 17:34:28
I think he means that you can just directly call t
tkent
2014/08/14 22:59:47
I meant
WebLocalFrameImpl* webLocalFrame =
|
| + webLocalFrame->removeSpellingMarkersUnderWords(words); |
| + } |
| +} |
| + |
| WebDragOperation WebViewImpl::dragTargetDragEnterOrOver(const WebPoint& clientPoint, const WebPoint& screenPoint, DragAction dragAction, int keyModifiers) |
| { |
| ASSERT(m_currentDragData); |