From 3f4aec8db12813db8228b94383cdcaeba326c860 Mon Sep 17 00:00:00 2001 From: "jst%mozilla.jstenback.com" Date: Fri, 19 Aug 2005 22:56:20 +0000 Subject: [PATCH] Fixing bug 303765. Don't ever reuse a listener manager on a new inner window. r=sfraser_bugs@smfr.org, sr=brendan@mozilla.org git-svn-id: svn://10.0.0.236/trunk@178308 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/dom/src/base/nsGlobalWindow.cpp | 8 -------- 1 file changed, 8 deletions(-) diff --git a/mozilla/dom/src/base/nsGlobalWindow.cpp b/mozilla/dom/src/base/nsGlobalWindow.cpp index 5cce13a8033..8977ab8f032 100644 --- a/mozilla/dom/src/base/nsGlobalWindow.cpp +++ b/mozilla/dom/src/base/nsGlobalWindow.cpp @@ -894,10 +894,6 @@ nsGlobalWindow::SetNewDocument(nsIDOMDocument* aDocument, nsGlobalWindow *currentInner = GetCurrentInnerWindowInternal(); - // In case we're not removing event listeners, move the event - // listener manager over to the new inner window. - nsCOMPtr listenerManager; - if (currentInner && !currentInner->IsFrozen()) { if (!reUseInnerWindow) { currentInner->ClearAllTimeouts(); @@ -917,8 +913,6 @@ nsGlobalWindow::SetNewDocument(nsIDOMDocument* aDocument, if (aRemoveEventListeners && currentInner->mListenerManager) { currentInner->mListenerManager->RemoveAllListeners(PR_FALSE); currentInner->mListenerManager = nsnull; - } else { - listenerManager = currentInner->mListenerManager; } nsWindowSH::InvalidateGlobalScopePolluter(cx, currentInner->mJSObject); @@ -1069,8 +1063,6 @@ nsGlobalWindow::SetNewDocument(nsIDOMDocument* aDocument, html_doc); } - newInnerWindow->mListenerManager = listenerManager; - // InitClassesWithNewWrappedGlobal() for the new inner window sets // the global object in cx to be the new wrapped global. We don't // want that, but re-initializing the outer window will fix that