From 57e6536fa4d211024d69d344d0e500fbbf2cc22c Mon Sep 17 00:00:00 2001 From: Matt Brubeck Date: Wed, 1 Feb 2012 16:20:13 -0800 Subject: [PATCH] Bug 723084 - Remove observers when tabs are destroyed [r=bnicholson] --- mobile/android/chrome/content/browser.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index 8e111990bf6..5df8947c827 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -1508,6 +1508,8 @@ Tab.prototype = { this.browser.removeEventListener("pagehide", this, true); this.browser.removeEventListener("pageshow", this, true); + Services.obs.removeObserver(this, "document-shown"); + // Make sure the previously selected panel remains selected. The selected panel of a deck is // not stable when panels are removed. let selectedPanel = BrowserApp.deck.selectedPanel;