Bug 1560587 - Remove incorrect event redirection. r=tnikkel, a=jcristau
authorKartikaya Gupta <kgupta@mozilla.com>
Mon, 24 Jun 2019 20:10:40 +0000
changeset 534023 a9beb454bd6cfd5bb1045d5d255e07bc54acd5d2
parent 534022 7d0117af32b0b354696f1510a772c2e43d338968
child 534024 00c027a75c1cb7eff3d58b029f6764019abbb8ac
push id11498
push userjcristau@mozilla.com
push dateWed, 26 Jun 2019 09:03:59 +0000
treeherdermozilla-beta@6249480cfc31 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstnikkel, jcristau
Bug 1560587 - Remove incorrect event redirection. r=tnikkel, a=jcristau In this codepath, the parent process may be sending an event to a particular content process. The last-saved mouse target might be stale, and using that to redirect the event can result in the event getting sent to the wront content process. Deleting this erroneous change restores correct behaviour. Differential Revision: https://phabricator.services.mozilla.com/D35697
--- a/layout/base/PresShell.cpp
+++ b/layout/base/PresShell.cpp
@@ -5524,21 +5524,16 @@ void PresShell::ProcessSynthMouseMoveEve
   // XXX mnakano I think that we should get the latest information from widget.
   if (BrowserBridgeChild* bbc = GetChildBrowser(pointView)) {
     // If we have a BrowserBridgeChild, we're going to be dispatching this
     // mouse event into an OOP iframe of the current document.
     event.mLayersId = bbc->GetLayersId();
   } else if (RefPtr<PresShell> presShell = pointVM->GetPresShell()) {
-    // Otherwise we're targetting regular (non-OOP iframe) content in the
-    // current process. This field probably won't even be read, but we
-    // can fill it in with a sane value.
-    event.mLayersId = mMouseEventTargetGuid.mLayersId;
     // Since this gets run in a refresh tick there isn't an InputAPZContext on
     // the stack from the nsBaseWidget. We need to simulate one with at least
     // the correct target guid, so that the correct callback transform gets
     // applied if this event goes to a child process. The input block id is set
     // to 0 because this is a synthetic event which doesn't really belong to any
     // input block. Same for the APZ response field.
     InputAPZContext apzContext(mMouseEventTargetGuid, 0, nsEventStatus_eIgnore);