Chromium Code Reviews| Index: content/renderer/pepper/pepper_plugin_instance_impl.cc |
| diff --git a/content/renderer/pepper/pepper_plugin_instance_impl.cc b/content/renderer/pepper/pepper_plugin_instance_impl.cc |
| index 29625e4a049ad9d5f3e9ebfd89b88307133d92e3..452a35ba8f3c3f8592bb0b34829ce5a343abbc99 100644 |
| --- a/content/renderer/pepper/pepper_plugin_instance_impl.cc |
| +++ b/content/renderer/pepper/pepper_plugin_instance_impl.cc |
| @@ -179,6 +179,7 @@ using blink::WebURLResponse; |
| using blink::WebUserGestureIndicator; |
| using blink::WebUserGestureToken; |
| using blink::WebView; |
| +using blink::WebWidget; |
| namespace content { |
| @@ -2190,8 +2191,9 @@ void PepperPluginInstanceImpl::HandleMouseLockedInputEvent( |
| void PepperPluginInstanceImpl::SimulateInputEvent( |
| const InputEventData& input_event) { |
| - WebView* web_view = container()->document().frame()->view(); |
| - if (!web_view) { |
| + WebWidget* widget = |
| + container()->document().frame()->localRoot()->frameWidget(); |
|
alexmos
2016/07/07 21:17:19
This function didn't work in OOPIF processes, sinc
|
| + if (!widget) { |
| NOTREACHED(); |
| return; |
| } |
| @@ -2207,7 +2209,7 @@ void PepperPluginInstanceImpl::SimulateInputEvent( |
| for (std::vector<std::unique_ptr<WebInputEvent>>::iterator it = |
| events.begin(); |
| it != events.end(); ++it) { |
| - web_view->handleInputEvent(*it->get()); |
| + widget->handleInputEvent(*it->get()); |
| } |
| } |