Bug 924971 - [Contacts] Trying to add a contact as a recipient opens contact details instead of returning to Messages app. r=fabrice
☠☠ backed out by cd77d501b40c ☠ ☠
authorFernando Jiménez <ferjmoreno@gmail.com>
Thu, 17 Oct 2013 22:29:59 +0200
changeset 164980 5349c5c0d9f86856d847e1d6a8f8e6d5f68a9114
parent 164979 253257d650a6b201e3acc6326d6344ccad969ca4
child 164981 03b50ae14f9bd4dc764d6ef2ddbf260ca613406e
push id3066
push userakeybl@mozilla.com
push dateMon, 09 Dec 2013 19:58:46 +0000
treeherdermozilla-beta@a31a0dce83aa [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfabrice
bugs924971
milestone27.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 924971 - [Contacts] Trying to add a contact as a recipient opens contact details instead of returning to Messages app. r=fabrice
dom/base/DOMRequestHelper.jsm
dom/messages/SystemMessageManager.js
--- a/dom/base/DOMRequestHelper.jsm
+++ b/dom/base/DOMRequestHelper.jsm
@@ -47,17 +47,18 @@ this.DOMRequestIpcHelper = function DOMR
 }
 
 DOMRequestIpcHelper.prototype = {
   /**
    * An object which "inherits" from DOMRequestIpcHelper, declares its own
    * queryInterface method and adds at least one weak listener to the Message
    * Manager MUST implement Ci.nsISupportsWeakReference.
    */
-  QueryInterface: XPCOMUtils.generateQI([Ci.nsISupportsWeakReference]),
+  QueryInterface: XPCOMUtils.generateQI([Ci.nsISupportsWeakReference,
+                                         Ci.nsIObserver]),
 
    /**
    *  'aMessages' is expected to be an array of either:
    *  - objects of this form:
    *    {
    *      name: "messageName",
    *      strongRef: false
    *    }
--- a/dom/messages/SystemMessageManager.js
+++ b/dom/messages/SystemMessageManager.js
@@ -279,16 +279,19 @@ SystemMessageManager.prototype = {
 
     debug("done");
   },
 
   observe: function sysMessMgr_observe(aSubject, aTopic, aData) {
     if (aTopic === kSystemMessageInternalReady) {
       this._registerManifest();
     }
+
+    // Call the DOMRequestIpcHelper.observe method.
+    this.__proto__.__proto__.observe.call(this, aSubject, aTopic, aData);
   },
 
   _registerManifest: function sysMessMgr_registerManifest() {
     if (this._isInBrowserElement) {
       debug("the app loaded in the browser doesn't need to register " +
             "the manifest for listening to the system messages");
       return;
     }