Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(115)

Unified Diff: third_party/WebKit/Source/web/WebInputMethodControllerImpl.cpp

Issue 2888203006: Move the logic to retrieve the WebPluginContainer to LocalFrame and Node. (Closed)
Patch Set: Rename & format. Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/web/WebInputMethodControllerImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebInputMethodControllerImpl.cpp b/third_party/WebKit/Source/web/WebInputMethodControllerImpl.cpp
index b1ed72e6131dbd161b54a432dfae687ec0b34b55..4904552fb870447ae6fb16914b96736c7bc2ed4f 100644
--- a/third_party/WebKit/Source/web/WebInputMethodControllerImpl.cpp
+++ b/third_party/WebKit/Source/web/WebInputMethodControllerImpl.cpp
@@ -158,10 +158,11 @@ InputMethodController& WebInputMethodControllerImpl::GetInputMethodController()
WebPlugin* WebInputMethodControllerImpl::FocusedPluginIfInputMethodSupported()
const {
- WebPluginContainerBase* container =
- WebLocalFrameImpl::CurrentPluginContainer(GetFrame());
- if (container && container->SupportsInputMethod())
- return container->Plugin();
+ if (GetFrame()) {
dcheng 2017/05/19 09:07:02 This GetFrame() check shouldn't be required. We p
slangley 2017/05/21 23:53:33 Removed the check - no other methods have it.
+ WebPluginContainerBase* container = GetFrame()->GetWebPluginContainerBase();
+ if (container && container->SupportsInputMethod())
+ return container->Plugin();
+ }
return nullptr;
}

Powered by Google App Engine
This is Rietveld 408576698