Bug 1275932, use AutoHandlingUserInputStatePusher to indicate that a real input is happening when refiring key event in the parent process, r=masayuki
authorNeil Deakin <neil@mozilla.com>
Mon, 25 Jul 2016 09:08:49 -0400
changeset 346581 81fa78eb62f6ff8eb0b392105e43b7122f04df90
parent 346580 6acbad99a3ff13f56a1157830cc0ac93379c0d24
child 346582 9b361e455e6ab4c37c9368d5b9c914b22997efb7
push id6389
push userraliiev@mozilla.com
push dateMon, 19 Sep 2016 13:38:22 +0000
treeherdermozilla-beta@01d67bfe6c81 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmasayuki
bugs1275932
milestone50.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1275932, use AutoHandlingUserInputStatePusher to indicate that a real input is happening when refiring key event in the parent process, r=masayuki
dom/ipc/TabParent.cpp
--- a/dom/ipc/TabParent.cpp
+++ b/dom/ipc/TabParent.cpp
@@ -2113,16 +2113,19 @@ TabParent::RecvReplyKeyEvent(const Widge
   // Here we convert the WidgetEvent that we received to an nsIDOMEvent
   // to be able to dispatch it to the <browser> element as the target element.
   nsIDocument* doc = mFrameElement->OwnerDoc();
   nsIPresShell* presShell = doc->GetShell();
   NS_ENSURE_TRUE(presShell, true);
   nsPresContext* presContext = presShell->GetPresContext();
   NS_ENSURE_TRUE(presContext, true);
 
+  AutoHandlingUserInputStatePusher userInpStatePusher(localEvent.IsTrusted(),
+                                                      &localEvent, doc);
+
   EventDispatcher::Dispatch(mFrameElement, presContext, &localEvent);
   return true;
 }
 
 bool
 TabParent::RecvDispatchAfterKeyboardEvent(const WidgetKeyboardEvent& aEvent)
 {
   NS_ENSURE_TRUE(mFrameElement, true);