Permalink
Browse files

Merge branch 'hotfix/cpu'

  • Loading branch information...
2 parents 0df924b + a549fa4 commit 14552146ca154411e9563993b62f8423e8bd83ca @jrburke jrburke committed Apr 1, 2011
Showing with 3 additions and 19 deletions.
  1. +1 −1 extensions/firefox-share/src/install.rdf
  2. +2 −18 extensions/firefox-share/src/modules/panel.js
@@ -6,7 +6,7 @@
<em:unpack>true</em:unpack>
<em:bootstrap>true</em:bootstrap>
<em:name>F1 by Mozilla Labs</em:name>
- <em:version>0.8.1</em:version>
+ <em:version>0.8.2</em:version>
<em:creator>Mozilla</em:creator>
<em:contributor></em:contributor>
<em:homepageURL>http://f1.mozillamessaging.com/</em:homepageURL>
@@ -104,12 +104,12 @@ sharePanel.prototype = {
}
}, false);
this.loadListener = function (evt) {
+ self.attachMessageListener();
self.window.setTimeout(function () {
self.sizeToContent();
}, 0);
};
this.browser.addEventListener("load", this.loadListener, true);
- Services.obs.addObserver(this, 'content-document-global-created', false);
let webProgress = this.browser.webProgress;
this.stateProgressListener = new StateProgressListener(this);
@@ -124,28 +124,12 @@ sharePanel.prototype = {
},
shutdown: function () {
- Services.obs.removeObserver(this, 'content-document-global-created');
let webProgress = this.browser.webProgress;
webProgress.removeProgressListener(this.stateProgressListener);
this.stateProgressListener = null;
},
- observe: function (aSubject, aTopic, aData) {
- if (!aSubject.location.href) {
- return;
- }
-
- // is this window a child of OUR XUL window?
- let mainWindow = aSubject.QueryInterface(Ci.nsIInterfaceRequestor)
- .getInterface(Ci.nsIWebNavigation)
- .QueryInterface(Ci.nsIDocShellTreeItem)
- .rootTreeItem.QueryInterface(Ci.nsIInterfaceRequestor)
- .getInterface(Ci.nsIDOMWindow);
- mainWindow = mainWindow.wrappedJSObject ? mainWindow.wrappedJSObject : mainWindow;
- if (mainWindow !== this.panel.ownerDocument.defaultView) {
- return;
- }
-
+ attachMessageListener: function () {
// listen for messages now
let self = this;
let contentWindow = this.browser.contentWindow;

0 comments on commit 1455214

Please sign in to comment.