Index: content/browser/renderer_host/render_widget_host_view_event_handler.cc |
diff --git a/content/browser/renderer_host/render_widget_host_view_event_handler.cc b/content/browser/renderer_host/render_widget_host_view_event_handler.cc |
index bdfc55a994f929f6793cff68b647edbe62d3a102..f00420c1ee93afcd5c87c995fc61dc5a48e405c8 100644 |
--- a/content/browser/renderer_host/render_widget_host_view_event_handler.cc |
+++ b/content/browser/renderer_host/render_widget_host_view_event_handler.cc |
@@ -248,6 +248,7 @@ void RenderWidgetHostViewEventHandler::OnKeyEvent(ui::KeyEvent* event) { |
return; |
} |
+ bool mark_event_as_handled = true; |
// We need to handle the Escape key for Pepper Flash. |
if (host_view_->is_fullscreen() && event->key_code() == ui::VKEY_ESCAPE) { |
// Focus the window we were created from. |
@@ -283,9 +284,10 @@ void RenderWidgetHostViewEventHandler::OnKeyEvent(ui::KeyEvent* event) { |
SetKeyboardFocus(); |
// We don't have to communicate with an input method here. |
NativeWebKeyboardEvent webkit_event(*event); |
- delegate_->ForwardKeyboardEvent(webkit_event); |
+ delegate_->ForwardKeyboardEvent(webkit_event, &mark_event_as_handled); |
} |
- event->SetHandled(); |
+ if (mark_event_as_handled) |
+ event->SetHandled(); |
} |
void RenderWidgetHostViewEventHandler::OnMouseEvent(ui::MouseEvent* event) { |