Bug 762717: Tab's onDestroy needs to clear the HashMap, and can be executed in background. [r=margaret]

--HG--
extra : rebase_source : a9494cbbca15a30993d39f939df250d25b831db0
This commit is contained in:
Sriram Ramasubramanian 2012-06-14 11:56:50 -07:00
parent a8447801e6
commit 1444b2fab2
2 changed files with 2 additions and 2 deletions

View File

@ -106,7 +106,7 @@ public final class Tab {
}
public void onDestroy() {
mDoorHangers = new HashMap<String, DoorHanger>();
mDoorHangers.clear();
BrowserDB.unregisterContentObserver(mContentResolver, mContentObserver);
}

View File

@ -161,11 +161,11 @@ public class Tabs implements GeckoEventListener {
int tabId = tab.getId();
removeTab(tabId);
tab.onDestroy();
GeckoApp.mAppContext.mMainHandler.post(new Runnable() {
public void run() {
notifyListeners(tab, TabEvents.CLOSED);
tab.onDestroy();
}
});