Make nsIPresShell::GetPrimaryFrameFor return nsIFrame* instead of using an out

param.  Bug 303779, patch by Bastiaan Jacques <b.jacques@planet.nl>, r+sr=bzbarsky


git-svn-id: svn://10.0.0.236/trunk@178642 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bzbarsky%mit.edu
2005-08-22 22:24:29 +00:00
parent 306d9c4922
commit d1afb179ba
72 changed files with 231 additions and 379 deletions

View File

@@ -3629,8 +3629,7 @@ nsDocShell::GetVisibility(PRBool * aVisibility)
pPresShell->GetDocument()->FindContentForSubDocument(presShell->GetDocument());
NS_ASSERTION(shellContent, "subshell not in the map");
nsIFrame* frame;
pPresShell->GetPrimaryFrameFor(shellContent, &frame);
nsIFrame* frame = pPresShell->GetPrimaryFrameFor(shellContent);
if (frame && !frame->AreAncestorViewsVisible()) {
*aVisibility = PR_FALSE;
return NS_OK;
@@ -8138,8 +8137,7 @@ nsDocShell::SetCanvasHasFocus(PRBool aCanvasHasFocus)
nsIContent *rootContent = doc->GetRootContent();
if (!rootContent) return NS_ERROR_FAILURE;
nsIFrame* frame;
presShell->GetPrimaryFrameFor(rootContent, &frame);
nsIFrame* frame = presShell->GetPrimaryFrameFor(rootContent);
if (frame) {
frame = frame->GetParent();
if (frame) {