diff --git a/mozilla/content/base/src/nsDocumentViewer.cpp b/mozilla/content/base/src/nsDocumentViewer.cpp index 8bfb74f840b..fba50729b19 100644 --- a/mozilla/content/base/src/nsDocumentViewer.cpp +++ b/mozilla/content/base/src/nsDocumentViewer.cpp @@ -350,9 +350,6 @@ public: // nsIDocumentViewerPrint Printing Methods NS_DECL_NSIDOCUMENTVIEWERPRINT - // Helpers (also used by nsPrintEngine) - PRBool IsWebShellAFrameSet(nsIWebShell * aParent); - protected: virtual ~DocumentViewerImpl(); @@ -1688,92 +1685,7 @@ DocumentViewerImpl::CreateStyleSet(nsIDocument* aDocument, } -//--------------------------------------------------------------------- -// Note this is also defined in nsPrintEngine -// They can't share it because nsPrintEngine may not be available -// when printing isn't turned on -static nsIPresShell * -GetPresShellFor(nsIDocShell* aDocShell) -{ - nsCOMPtr domDoc(do_GetInterface(aDocShell)); - if (!domDoc) return nsnull; - - nsCOMPtr doc(do_QueryInterface(domDoc)); - if (!doc) return nsnull; - - return doc->GetShellAt(0); -} - -//--------------------------------------------------------------------- -// This gets ref counted copies of the PresShell and Root Content -// for a given nsIWebShell -void -DocumentViewerImpl::GetPresShellAndRootContent(nsIWebShell * aWebShell, - nsIPresShell** aPresShell, - nsIContent** aContent) -{ - NS_ASSERTION(aWebShell, "Pointer is null!"); - NS_ASSERTION(aPresShell, "Pointer is null!"); - NS_ASSERTION(aContent, "Pointer is null!"); - - *aContent = nsnull; - *aPresShell = nsnull; - - nsCOMPtr docShell(do_QueryInterface(aWebShell)); - - nsIPresShell *presShell = GetPresShellFor(docShell); - if (!presShell) - return; - - nsCOMPtr doc; - presShell->GetDocument(getter_AddRefs(doc)); - if (!doc) - return; - - NS_IF_ADDREF(*aContent = doc->GetRootContent()); - NS_ADDREF(*aPresShell = presShell); -} - -//--------------------------------------------------------------------- -nsresult -DocumentViewerImpl::FindFrameSetWithIID(nsIContent * aParentContent, - const nsIID& aIID) -{ - PRUint32 numChildren = aParentContent->GetChildCount(); - - // do a breadth search across all siblings - PRUint32 inx; - for (inx = 0; inx < numChildren; ++inx) { - nsIContent *child = aParentContent->GetChildAt(inx); - - if (child) { - nsCOMPtr temp; - if (NS_SUCCEEDED(child->QueryInterface(aIID, (void**)getter_AddRefs(temp)))) { - return NS_OK; - } - } - } - - return NS_ERROR_FAILURE; -} - //------------------------------------------------------- -PRBool -DocumentViewerImpl::IsWebShellAFrameSet(nsIWebShell * aWebShell) -{ - NS_ASSERTION(aWebShell, "Pointer is null!"); - - PRBool doesContainFrameSet = PR_FALSE; - nsCOMPtr presShell; - nsCOMPtr rootContent; - GetPresShellAndRootContent(aWebShell, getter_AddRefs(presShell), getter_AddRefs(rootContent)); - if (rootContent) { - if (NS_SUCCEEDED(FindFrameSetWithIID(rootContent, NS_GET_IID(nsIDOMHTMLFrameSetElement)))) { - doesContainFrameSet = PR_TRUE; - } - } - return doesContainFrameSet; -} nsresult DocumentViewerImpl::MakeWindow(nsIWidget* aParentWidget, diff --git a/mozilla/content/base/src/nsIDocumentViewerPrint.h b/mozilla/content/base/src/nsIDocumentViewerPrint.h index 2aca4a8c07e..2186c486645 100644 --- a/mozilla/content/base/src/nsIDocumentViewerPrint.h +++ b/mozilla/content/base/src/nsIDocumentViewerPrint.h @@ -85,9 +85,6 @@ public: virtual void OnDonePrinting() = 0; - virtual nsresult FindFrameSetWithIID(nsIContent * aParentContent, const nsIID& aIID) = 0; - - virtual void GetPresShellAndRootContent(nsIWebShell * aWebShell, nsIPresShell** aPresShell, nsIContent** aContent) = 0; }; /* Use this macro when declaring classes that implement this interface. */ @@ -102,8 +99,6 @@ public: virtual void IncrementDestroyRefCount(); \ virtual void ReturnToGalleyPresentation(); \ virtual void InstallNewPresentation(); \ - virtual void OnDonePrinting(); \ - virtual nsresult FindFrameSetWithIID(nsIContent * aParentContent, const nsIID& aIID); \ - virtual void GetPresShellAndRootContent(nsIWebShell * aWebShell, nsIPresShell** aPresShell, nsIContent** aContent); + virtual void OnDonePrinting(); #endif /* nsIDocumentViewerPrint_h___ */ diff --git a/mozilla/content/base/src/nsPrintEngine.cpp b/mozilla/content/base/src/nsPrintEngine.cpp index a1ae19dd52b..c53d7e3eda2 100644 --- a/mozilla/content/base/src/nsPrintEngine.cpp +++ b/mozilla/content/base/src/nsPrintEngine.cpp @@ -1372,7 +1372,7 @@ nsPrintEngine::EnumerateDocumentNames(PRUint32* aCount, NS_ASSERTION(po, "nsPrintObject can't be null!"); PRUnichar * docTitleStr; PRUnichar * docURLStr; - GetWebShellTitleAndURL(po->mWebShell, po->mDocument, &docTitleStr, &docURLStr); + GetDocumentTitleAndURL(po->mDocument, &docTitleStr, &docURLStr); // Use the URL if the doc is empty if (!docTitleStr || !*docTitleStr) { @@ -1770,9 +1770,7 @@ nsPrintEngine::IsParentAFrameSet(nsIWebShell * aParent) if (doc) { nsIContent *rootContent = doc->GetRootContent(); if (rootContent) { - if (NS_SUCCEEDED(mDocViewerPrint->FindFrameSetWithIID(rootContent, NS_GET_IID(nsIDOMHTMLFrameSetElement)))) { - isFrameSet = PR_TRUE; - } + isFrameSet = HasFramesetChild(rootContent); } } } @@ -1793,7 +1791,7 @@ nsPrintEngine::BuildDocTree(nsIDocShellTreeNode * aParentNode, NS_ASSERTION(aPO, "Pointer is null!"); // Get the Doc and Title String - GetWebShellTitleAndURL(aPO->mWebShell, aPO->mDocument, &aPO->mDocTitle, &aPO->mDocURL); + GetDocumentTitleAndURL(aPO->mDocument, &aPO->mDocTitle, &aPO->mDocURL); PRInt32 childWebshellCount; aParentNode->GetChildCount(&childWebshellCount); @@ -1833,12 +1831,10 @@ nsPrintEngine::BuildDocTree(nsIDocShellTreeNode * aParentNode, //--------------------------------------------------------------------- void -nsPrintEngine::GetWebShellTitleAndURL(nsIWebShell* aWebShell, - nsIDocument* aDoc, +nsPrintEngine::GetDocumentTitleAndURL(nsIDocument* aDoc, PRUnichar** aTitle, PRUnichar** aURLStr) { - NS_ASSERTION(aWebShell, "Pointer is null!"); NS_ASSERTION(aDoc, "Pointer is null!"); NS_ASSERTION(aTitle, "Pointer is null!"); NS_ASSERTION(aURLStr, "Pointer is null!"); @@ -1875,7 +1871,7 @@ nsPrintEngine::MapContentToWebShells(nsPrintObject* aRootPO, // Recursively walk the content from the root item nsCOMPtr presShell; nsCOMPtr rootContent; - mDocViewerPrint->GetPresShellAndRootContent(aPO->mWebShell, getter_AddRefs(presShell), getter_AddRefs(rootContent)); + GetPresShellAndRootContent(aPO->mDocShell, getter_AddRefs(presShell), getter_AddRefs(rootContent)); if (presShell && rootContent) { MapContentForPO(aRootPO, presShell, rootContent); } @@ -3886,23 +3882,6 @@ nsPrintEngine::GetPageRangeForSelection(nsIPresShell * aPresShell, //-- Section: Misc Support Methods //----------------------------------------------------------------- -//--------------------------------------------------------------------- -// Note this is also defined in DocumentViewerImpl -// static -nsIPresShell * -GetPresShellFor(nsIDocShell* aDocShell) -{ - nsCOMPtr domDoc(do_GetInterface(aDocShell)); - if (!domDoc) - return nsnull; - - nsCOMPtr doc(do_QueryInterface(domDoc)); - if (!doc) - return nsnull; - - return doc->GetShellAt(0); -} - //--------------------------------------------------------------------- void nsPrintEngine::SetIsPrinting(PRBool aIsPrinting) { @@ -3933,6 +3912,59 @@ nsPrintEngine::CleanupDocTitleArray(PRUnichar**& aArray, PRInt32& aCount) aArray = NULL; aCount = 0; } +//--------------------------------------------------------------------- +// This gets ref counted copies of the PresShell and Root Content +// for a given docshell +// static +void +nsPrintEngine::GetPresShellAndRootContent(nsIDocShell * aDocShell, + nsIPresShell** aPresShell, + nsIContent** aContent) +{ + NS_ASSERTION(aDocShell, "Pointer is null!"); + NS_ASSERTION(aPresShell, "Pointer is null!"); + NS_ASSERTION(aContent, "Pointer is null!"); + + *aContent = nsnull; + *aPresShell = nsnull; + + nsCOMPtr domDoc(do_GetInterface(aDocShell)); + + nsCOMPtr doc(do_QueryInterface(domDoc)); + if (!doc) + return; + + nsIPresShell *presShell = doc->GetShellAt(0); + if (!presShell) + return; + + NS_IF_ADDREF(*aContent = doc->GetRootContent()); + NS_ADDREF(*aPresShell = presShell); +} + +//--------------------------------------------------------------------- +// static +PRBool nsPrintEngine::HasFramesetChild(nsIContent* aContent) +{ + if (!aContent) { + return PR_FALSE; + } + + PRUint32 numChildren = aContent->GetChildCount(); + + // do a breadth search across all siblings + for (PRUint32 i = 0; i < numChildren; ++i) { + nsIContent *child = aContent->GetChildAt(i); + if (child->Tag() == nsHTMLAtoms::frameset && + child->IsContentOfType(nsIContent::eHTML)) { + return PR_TRUE; + } + } + + return PR_FALSE; +} + + /** --------------------------------------------------- * Get the Focused Frame for a documentviewer diff --git a/mozilla/content/base/src/nsPrintEngine.h b/mozilla/content/base/src/nsPrintEngine.h index a8f51da5837..87bb877b8d4 100644 --- a/mozilla/content/base/src/nsPrintEngine.h +++ b/mozilla/content/base/src/nsPrintEngine.h @@ -214,9 +214,6 @@ public: nsPrintObject* aPO, PRUint32 aDelay); - //--------------------------------------------------------------------- - // Static Methods - //--------------------------------------------------------------------- PRBool IsWindowsInOurSubTree(nsIDOMWindow * aDOMWindow); PRBool IsParentAFrameSet(nsIWebShell * aParent); PRBool IsThereAnIFrameSelected(nsIWebShell* aWebShell, @@ -229,9 +226,12 @@ public: // get the currently infocus frame for the document viewer already_AddRefed FindFocusedDOMWindow(); - void GetWebShellTitleAndURL(nsIWebShell* aWebShell, nsIDocument* aDoc, - PRUnichar** aTitle, PRUnichar** aURLStr); - + //--------------------------------------------------------------------- + // Static Methods + //--------------------------------------------------------------------- + static void GetDocumentTitleAndURL(nsIDocument* aDoc, + PRUnichar** aTitle, + PRUnichar** aURLStr); static void GetDisplayTitleAndURL(nsPrintObject* aPO, nsIPrintSettings* aPrintSettings, const PRUnichar* aBrandName, @@ -240,6 +240,11 @@ public: eDocTitleDefault aDefType = eDocTitleDefNone); static void ShowPrintErrorDialog(nsresult printerror, PRBool aIsPrinting = PR_TRUE); + static void GetPresShellAndRootContent(nsIDocShell * aDocShell, + nsIPresShell** aPresShell, + nsIContent** aContent); + + static PRBool HasFramesetChild(nsIContent* aContent); PRBool CheckBeforeDestroy(); nsresult Cancelled(); diff --git a/mozilla/layout/base/nsDocumentViewer.cpp b/mozilla/layout/base/nsDocumentViewer.cpp index 8bfb74f840b..fba50729b19 100644 --- a/mozilla/layout/base/nsDocumentViewer.cpp +++ b/mozilla/layout/base/nsDocumentViewer.cpp @@ -350,9 +350,6 @@ public: // nsIDocumentViewerPrint Printing Methods NS_DECL_NSIDOCUMENTVIEWERPRINT - // Helpers (also used by nsPrintEngine) - PRBool IsWebShellAFrameSet(nsIWebShell * aParent); - protected: virtual ~DocumentViewerImpl(); @@ -1688,92 +1685,7 @@ DocumentViewerImpl::CreateStyleSet(nsIDocument* aDocument, } -//--------------------------------------------------------------------- -// Note this is also defined in nsPrintEngine -// They can't share it because nsPrintEngine may not be available -// when printing isn't turned on -static nsIPresShell * -GetPresShellFor(nsIDocShell* aDocShell) -{ - nsCOMPtr domDoc(do_GetInterface(aDocShell)); - if (!domDoc) return nsnull; - - nsCOMPtr doc(do_QueryInterface(domDoc)); - if (!doc) return nsnull; - - return doc->GetShellAt(0); -} - -//--------------------------------------------------------------------- -// This gets ref counted copies of the PresShell and Root Content -// for a given nsIWebShell -void -DocumentViewerImpl::GetPresShellAndRootContent(nsIWebShell * aWebShell, - nsIPresShell** aPresShell, - nsIContent** aContent) -{ - NS_ASSERTION(aWebShell, "Pointer is null!"); - NS_ASSERTION(aPresShell, "Pointer is null!"); - NS_ASSERTION(aContent, "Pointer is null!"); - - *aContent = nsnull; - *aPresShell = nsnull; - - nsCOMPtr docShell(do_QueryInterface(aWebShell)); - - nsIPresShell *presShell = GetPresShellFor(docShell); - if (!presShell) - return; - - nsCOMPtr doc; - presShell->GetDocument(getter_AddRefs(doc)); - if (!doc) - return; - - NS_IF_ADDREF(*aContent = doc->GetRootContent()); - NS_ADDREF(*aPresShell = presShell); -} - -//--------------------------------------------------------------------- -nsresult -DocumentViewerImpl::FindFrameSetWithIID(nsIContent * aParentContent, - const nsIID& aIID) -{ - PRUint32 numChildren = aParentContent->GetChildCount(); - - // do a breadth search across all siblings - PRUint32 inx; - for (inx = 0; inx < numChildren; ++inx) { - nsIContent *child = aParentContent->GetChildAt(inx); - - if (child) { - nsCOMPtr temp; - if (NS_SUCCEEDED(child->QueryInterface(aIID, (void**)getter_AddRefs(temp)))) { - return NS_OK; - } - } - } - - return NS_ERROR_FAILURE; -} - //------------------------------------------------------- -PRBool -DocumentViewerImpl::IsWebShellAFrameSet(nsIWebShell * aWebShell) -{ - NS_ASSERTION(aWebShell, "Pointer is null!"); - - PRBool doesContainFrameSet = PR_FALSE; - nsCOMPtr presShell; - nsCOMPtr rootContent; - GetPresShellAndRootContent(aWebShell, getter_AddRefs(presShell), getter_AddRefs(rootContent)); - if (rootContent) { - if (NS_SUCCEEDED(FindFrameSetWithIID(rootContent, NS_GET_IID(nsIDOMHTMLFrameSetElement)))) { - doesContainFrameSet = PR_TRUE; - } - } - return doesContainFrameSet; -} nsresult DocumentViewerImpl::MakeWindow(nsIWidget* aParentWidget, diff --git a/mozilla/layout/base/nsIDocumentViewerPrint.h b/mozilla/layout/base/nsIDocumentViewerPrint.h index 2aca4a8c07e..2186c486645 100644 --- a/mozilla/layout/base/nsIDocumentViewerPrint.h +++ b/mozilla/layout/base/nsIDocumentViewerPrint.h @@ -85,9 +85,6 @@ public: virtual void OnDonePrinting() = 0; - virtual nsresult FindFrameSetWithIID(nsIContent * aParentContent, const nsIID& aIID) = 0; - - virtual void GetPresShellAndRootContent(nsIWebShell * aWebShell, nsIPresShell** aPresShell, nsIContent** aContent) = 0; }; /* Use this macro when declaring classes that implement this interface. */ @@ -102,8 +99,6 @@ public: virtual void IncrementDestroyRefCount(); \ virtual void ReturnToGalleyPresentation(); \ virtual void InstallNewPresentation(); \ - virtual void OnDonePrinting(); \ - virtual nsresult FindFrameSetWithIID(nsIContent * aParentContent, const nsIID& aIID); \ - virtual void GetPresShellAndRootContent(nsIWebShell * aWebShell, nsIPresShell** aPresShell, nsIContent** aContent); + virtual void OnDonePrinting(); #endif /* nsIDocumentViewerPrint_h___ */ diff --git a/mozilla/layout/printing/nsPrintEngine.cpp b/mozilla/layout/printing/nsPrintEngine.cpp index a1ae19dd52b..c53d7e3eda2 100644 --- a/mozilla/layout/printing/nsPrintEngine.cpp +++ b/mozilla/layout/printing/nsPrintEngine.cpp @@ -1372,7 +1372,7 @@ nsPrintEngine::EnumerateDocumentNames(PRUint32* aCount, NS_ASSERTION(po, "nsPrintObject can't be null!"); PRUnichar * docTitleStr; PRUnichar * docURLStr; - GetWebShellTitleAndURL(po->mWebShell, po->mDocument, &docTitleStr, &docURLStr); + GetDocumentTitleAndURL(po->mDocument, &docTitleStr, &docURLStr); // Use the URL if the doc is empty if (!docTitleStr || !*docTitleStr) { @@ -1770,9 +1770,7 @@ nsPrintEngine::IsParentAFrameSet(nsIWebShell * aParent) if (doc) { nsIContent *rootContent = doc->GetRootContent(); if (rootContent) { - if (NS_SUCCEEDED(mDocViewerPrint->FindFrameSetWithIID(rootContent, NS_GET_IID(nsIDOMHTMLFrameSetElement)))) { - isFrameSet = PR_TRUE; - } + isFrameSet = HasFramesetChild(rootContent); } } } @@ -1793,7 +1791,7 @@ nsPrintEngine::BuildDocTree(nsIDocShellTreeNode * aParentNode, NS_ASSERTION(aPO, "Pointer is null!"); // Get the Doc and Title String - GetWebShellTitleAndURL(aPO->mWebShell, aPO->mDocument, &aPO->mDocTitle, &aPO->mDocURL); + GetDocumentTitleAndURL(aPO->mDocument, &aPO->mDocTitle, &aPO->mDocURL); PRInt32 childWebshellCount; aParentNode->GetChildCount(&childWebshellCount); @@ -1833,12 +1831,10 @@ nsPrintEngine::BuildDocTree(nsIDocShellTreeNode * aParentNode, //--------------------------------------------------------------------- void -nsPrintEngine::GetWebShellTitleAndURL(nsIWebShell* aWebShell, - nsIDocument* aDoc, +nsPrintEngine::GetDocumentTitleAndURL(nsIDocument* aDoc, PRUnichar** aTitle, PRUnichar** aURLStr) { - NS_ASSERTION(aWebShell, "Pointer is null!"); NS_ASSERTION(aDoc, "Pointer is null!"); NS_ASSERTION(aTitle, "Pointer is null!"); NS_ASSERTION(aURLStr, "Pointer is null!"); @@ -1875,7 +1871,7 @@ nsPrintEngine::MapContentToWebShells(nsPrintObject* aRootPO, // Recursively walk the content from the root item nsCOMPtr presShell; nsCOMPtr rootContent; - mDocViewerPrint->GetPresShellAndRootContent(aPO->mWebShell, getter_AddRefs(presShell), getter_AddRefs(rootContent)); + GetPresShellAndRootContent(aPO->mDocShell, getter_AddRefs(presShell), getter_AddRefs(rootContent)); if (presShell && rootContent) { MapContentForPO(aRootPO, presShell, rootContent); } @@ -3886,23 +3882,6 @@ nsPrintEngine::GetPageRangeForSelection(nsIPresShell * aPresShell, //-- Section: Misc Support Methods //----------------------------------------------------------------- -//--------------------------------------------------------------------- -// Note this is also defined in DocumentViewerImpl -// static -nsIPresShell * -GetPresShellFor(nsIDocShell* aDocShell) -{ - nsCOMPtr domDoc(do_GetInterface(aDocShell)); - if (!domDoc) - return nsnull; - - nsCOMPtr doc(do_QueryInterface(domDoc)); - if (!doc) - return nsnull; - - return doc->GetShellAt(0); -} - //--------------------------------------------------------------------- void nsPrintEngine::SetIsPrinting(PRBool aIsPrinting) { @@ -3933,6 +3912,59 @@ nsPrintEngine::CleanupDocTitleArray(PRUnichar**& aArray, PRInt32& aCount) aArray = NULL; aCount = 0; } +//--------------------------------------------------------------------- +// This gets ref counted copies of the PresShell and Root Content +// for a given docshell +// static +void +nsPrintEngine::GetPresShellAndRootContent(nsIDocShell * aDocShell, + nsIPresShell** aPresShell, + nsIContent** aContent) +{ + NS_ASSERTION(aDocShell, "Pointer is null!"); + NS_ASSERTION(aPresShell, "Pointer is null!"); + NS_ASSERTION(aContent, "Pointer is null!"); + + *aContent = nsnull; + *aPresShell = nsnull; + + nsCOMPtr domDoc(do_GetInterface(aDocShell)); + + nsCOMPtr doc(do_QueryInterface(domDoc)); + if (!doc) + return; + + nsIPresShell *presShell = doc->GetShellAt(0); + if (!presShell) + return; + + NS_IF_ADDREF(*aContent = doc->GetRootContent()); + NS_ADDREF(*aPresShell = presShell); +} + +//--------------------------------------------------------------------- +// static +PRBool nsPrintEngine::HasFramesetChild(nsIContent* aContent) +{ + if (!aContent) { + return PR_FALSE; + } + + PRUint32 numChildren = aContent->GetChildCount(); + + // do a breadth search across all siblings + for (PRUint32 i = 0; i < numChildren; ++i) { + nsIContent *child = aContent->GetChildAt(i); + if (child->Tag() == nsHTMLAtoms::frameset && + child->IsContentOfType(nsIContent::eHTML)) { + return PR_TRUE; + } + } + + return PR_FALSE; +} + + /** --------------------------------------------------- * Get the Focused Frame for a documentviewer diff --git a/mozilla/layout/printing/nsPrintEngine.h b/mozilla/layout/printing/nsPrintEngine.h index a8f51da5837..87bb877b8d4 100644 --- a/mozilla/layout/printing/nsPrintEngine.h +++ b/mozilla/layout/printing/nsPrintEngine.h @@ -214,9 +214,6 @@ public: nsPrintObject* aPO, PRUint32 aDelay); - //--------------------------------------------------------------------- - // Static Methods - //--------------------------------------------------------------------- PRBool IsWindowsInOurSubTree(nsIDOMWindow * aDOMWindow); PRBool IsParentAFrameSet(nsIWebShell * aParent); PRBool IsThereAnIFrameSelected(nsIWebShell* aWebShell, @@ -229,9 +226,12 @@ public: // get the currently infocus frame for the document viewer already_AddRefed FindFocusedDOMWindow(); - void GetWebShellTitleAndURL(nsIWebShell* aWebShell, nsIDocument* aDoc, - PRUnichar** aTitle, PRUnichar** aURLStr); - + //--------------------------------------------------------------------- + // Static Methods + //--------------------------------------------------------------------- + static void GetDocumentTitleAndURL(nsIDocument* aDoc, + PRUnichar** aTitle, + PRUnichar** aURLStr); static void GetDisplayTitleAndURL(nsPrintObject* aPO, nsIPrintSettings* aPrintSettings, const PRUnichar* aBrandName, @@ -240,6 +240,11 @@ public: eDocTitleDefault aDefType = eDocTitleDefNone); static void ShowPrintErrorDialog(nsresult printerror, PRBool aIsPrinting = PR_TRUE); + static void GetPresShellAndRootContent(nsIDocShell * aDocShell, + nsIPresShell** aPresShell, + nsIContent** aContent); + + static PRBool HasFramesetChild(nsIContent* aContent); PRBool CheckBeforeDestroy(); nsresult Cancelled();