From 9e7ef16d9ae25d29a1c9b36ff9e8fccf940ae535 Mon Sep 17 00:00:00 2001 From: Wes Kocher Date: Mon, 2 Nov 2015 13:29:30 -0800 Subject: [PATCH] Backed out changeset 54c770bf243e (bug 1194525) for apparently causing a spike in gij(11/12) failures a=merge --- dom/activities/ActivityRequestHandler.js | 15 ++++++--------- dom/activities/ActivityWrapper.js | 5 +---- dom/webidl/ActivityRequestHandler.webidl | 2 +- 3 files changed, 8 insertions(+), 14 deletions(-) diff --git a/dom/activities/ActivityRequestHandler.js b/dom/activities/ActivityRequestHandler.js index 1c40c3d6a05..ffe1504eb58 100644 --- a/dom/activities/ActivityRequestHandler.js +++ b/dom/activities/ActivityRequestHandler.js @@ -36,10 +36,9 @@ ActivityRequestHandler.prototype = { this._window = aWindow; }, - __init: function arh___init(aId, aOptions, aReturnValue) { + __init: function arh___init(aId, aOptions) { this._id = aId; this._options = aOptions; - this._returnValue = aReturnValue; }, get source() { @@ -50,13 +49,11 @@ ActivityRequestHandler.prototype = { }, postResult: function arh_postResult(aResult) { - if (this._returnValue) { - cpmm.sendAsyncMessage("Activity:PostResult", { - "id": this._id, - "result": aResult - }); - Services.obs.notifyObservers(null, "activity-success", this._id); - } + cpmm.sendAsyncMessage("Activity:PostResult", { + "id": this._id, + "result": aResult + }); + Services.obs.notifyObservers(null, "activity-success", this._id); }, postError: function arh_postError(aError) { diff --git a/dom/activities/ActivityWrapper.js b/dom/activities/ActivityWrapper.js index 34427fddcd3..a9e81c428f9 100644 --- a/dom/activities/ActivityWrapper.js +++ b/dom/activities/ActivityWrapper.js @@ -37,10 +37,7 @@ ActivityWrapper.prototype = { // Activity workflow. cpmm.sendAsyncMessage("Activity:Ready", { id: aMessage.id }); - // Gecko should ignore |postResult| calls for WebActivities with no returnValue - // We need to pass returnValue to ActivityRequestHandler constructor to then properly - // decide if should call postResult or not - let handler = new aWindow.ActivityRequestHandler(aMessage.id, aMessage.payload, aMessage.target.returnValue); + let handler = new aWindow.ActivityRequestHandler(aMessage.id, aMessage.payload); // When the activity window is closed, fire an error to notify the activity // caller of the situation. diff --git a/dom/webidl/ActivityRequestHandler.webidl b/dom/webidl/ActivityRequestHandler.webidl index 7fc19664792..3d0f930cdc5 100644 --- a/dom/webidl/ActivityRequestHandler.webidl +++ b/dom/webidl/ActivityRequestHandler.webidl @@ -4,7 +4,7 @@ [Pref="dom.sysmsg.enabled", JSImplementation="@mozilla.org/dom/activities/request-handler;1", - ChromeConstructor(DOMString id, optional ActivityOptions options, optional boolean returnvalue), + ChromeConstructor(DOMString id, optional ActivityOptions options), ChromeOnly] interface ActivityRequestHandler {