bug = 117072. r=rods sr=attinasi. set the paintbackground to true before paint. Fixes paint preview.

git-svn-id: svn://10.0.0.236/trunk@111571 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
dcone%netscape.com
2002-01-08 14:58:52 +00:00
parent a971e57847
commit 9fbb0ab01d
2 changed files with 30 additions and 2 deletions

View File

@@ -601,9 +601,23 @@ nsGfxScrollFrame::Paint(nsIPresContext* aPresContext,
nsFramePaintLayer aWhichLayer,
PRUint32 aFlags)
{
nsresult result;
// there are some mechanisms to turn off background painting for print and print preview, these
// need to be turned on for the time being.. just for this paint.. then reset to the
// original values before this routine returns.
PRBool canDraw;
aPresContext->GetBackgroundDraw(canDraw);
aPresContext->SetBackgroundDraw(PR_TRUE);
// Paint our children
return nsBoxFrame::Paint(aPresContext, aRenderingContext, aDirtyRect,
result = nsBoxFrame::Paint(aPresContext, aRenderingContext, aDirtyRect,
aWhichLayer);
aPresContext->SetBackgroundDraw(canDraw);
return result;
}
NS_IMETHODIMP