Backed out changeset 3411c3d9c141 (bug 1318506)
authorSebastian Hengst <archaeopteryx@coole-files.de>
Thu, 01 Dec 2016 13:35:23 +0100
changeset 325006 237125712ba359a94f5f7f91e9884be64269e9a4
parent 325005 9efd9724f08fd0dfe83f1deafe5375b12f6111ad
child 325007 e36f92b56d8146438954a910a053d8df5715686b
push id24
push usermaklebus@msu.edu
push dateTue, 20 Dec 2016 03:11:33 +0000
bugs1318506
milestone53.0a1
backs out3411c3d9c141131f7bab910231d71d80c7b4ddf2
Backed out changeset 3411c3d9c141 (bug 1318506)
dom/plugins/ipc/PluginModuleParent.cpp
--- a/dom/plugins/ipc/PluginModuleParent.cpp
+++ b/dom/plugins/ipc/PluginModuleParent.cpp
@@ -2751,29 +2751,16 @@ PluginModuleParent::NPP_NewInternal(NPMI
     }
 
     // Release the surrogate reference that was in pdata
     RefPtr<PluginAsyncSurrogate> surrogate(
         dont_AddRef(PluginAsyncSurrogate::Cast(instance)));
     // Now replace it with the instance
     instance->pdata = static_cast<PluginDataResolver*>(parentInstance);
 
-    // Any IPC messages for the PluginInstance actor should be dispatched to the
-    // DocGroup for the plugin's document.
-    RefPtr<nsPluginInstanceOwner> owner = parentInstance->GetOwner();
-    nsCOMPtr<nsIDOMElement> elt;
-    owner->GetDOMElement(getter_AddRefs(elt));
-    if (nsCOMPtr<nsINode> node = do_QueryInterface(elt)) {
-        nsCOMPtr<nsIDocument> doc = node->OwnerDoc();
-        if (doc) {
-            nsCOMPtr<nsIEventTarget> eventTarget = doc->EventTargetFor(dom::TaskCategory::Other);
-            SetEventTargetForActor(parentInstance, eventTarget);
-        }
-    }
-
     if (!SendPPluginInstanceConstructor(parentInstance,
                                         nsDependentCString(pluginType), mode,
                                         names, values)) {
         // |parentInstance| is automatically deleted.
         instance->pdata = nullptr;
         *error = NPERR_GENERIC_ERROR;
         return NS_ERROR_FAILURE;
     }