зеркало из https://github.com/mozilla/pjs.git
Bug 433132, Running mochitest for bug 396024 still leaks r+sr=roc
This commit is contained in:
Родитель
20f1d43d97
Коммит
0b43e267f4
|
@ -1313,10 +1313,8 @@ DocumentViewerImpl::Close(nsISHEntry *aSHEntry)
|
|||
// A Close was called while we were printing
|
||||
// so don't clear the ScriptGlobalObject
|
||||
// or clear the mDocument below
|
||||
// Also, do an extra addref to keep the viewer from going away.
|
||||
if (mPrintEngine && !mClosingWhilePrinting) {
|
||||
mClosingWhilePrinting = PR_TRUE;
|
||||
NS_ADDREF_THIS();
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
|
@ -4074,7 +4072,6 @@ DocumentViewerImpl::OnDonePrinting()
|
|||
mDocument = nsnull;
|
||||
}
|
||||
mClosingWhilePrinting = PR_FALSE;
|
||||
NS_RELEASE_THIS();
|
||||
}
|
||||
if (mPresContext)
|
||||
mPresContext->RestoreImageAnimationMode();
|
||||
|
|
|
@ -229,7 +229,6 @@ nsPrintEngine::nsPrintEngine() :
|
|||
mIsDoingPrinting(PR_FALSE),
|
||||
mIsDoingPrintPreview(PR_FALSE),
|
||||
mProgressDialogIsShown(PR_FALSE),
|
||||
mDocViewerPrint(nsnull),
|
||||
mContainer(nsnull),
|
||||
mDeviceContext(nsnull),
|
||||
mPrt(nsnull),
|
||||
|
@ -269,7 +268,7 @@ void nsPrintEngine::Destroy()
|
|||
}
|
||||
|
||||
#endif
|
||||
|
||||
mDocViewerPrint = nsnull;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------
|
||||
|
@ -299,7 +298,7 @@ nsresult nsPrintEngine::Initialize(nsIDocumentViewerPrint* aDocViewerPrint,
|
|||
NS_ENSURE_ARG_POINTER(aDevContext);
|
||||
NS_ENSURE_ARG_POINTER(aParentWidget);
|
||||
|
||||
mDocViewerPrint = aDocViewerPrint; // weak reference
|
||||
mDocViewerPrint = aDocViewerPrint;
|
||||
mContainer = aContainer; // weak reference
|
||||
mDocument = aDocument;
|
||||
mDeviceContext = aDevContext; // weak reference
|
||||
|
|
|
@ -280,7 +280,7 @@ protected:
|
|||
PRPackedBool mIsDoingPrintPreview; // per DocumentViewer
|
||||
PRPackedBool mProgressDialogIsShown;
|
||||
|
||||
nsIDocumentViewerPrint* mDocViewerPrint; // [WEAK] it owns me!
|
||||
nsCOMPtr<nsIDocumentViewerPrint> mDocViewerPrint;
|
||||
nsISupports* mContainer; // [WEAK] it owns me!
|
||||
nsIDeviceContext* mDeviceContext; // not ref counted
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче