fix "window resizing in script causes content to be drawn on top of toolbars and tabstrip chrome". b=380192 r=smorgan sr=jst

This commit is contained in:
joshmoz@gmail.com 2007-07-06 17:28:29 -07:00
parent 908616f11e
commit be05cfa434

View File

@ -739,8 +739,10 @@ NS_IMETHODIMP nsCocoaWindow::Resize(PRInt32 aWidth, PRInt32 aHeight, PRBool aRep
StopResizing();
}
mBounds.width = aWidth;
mBounds.height = aHeight;
// report the actual size of the window because it can be restricted
NSRect finalWindowFrame = [mWindow contentRectForFrameRect:[mWindow frame]];
mBounds.width = (nscoord)finalWindowFrame.size.width;
mBounds.height = (nscoord)finalWindowFrame.size.height;
// tell gecko to update all the child widgets
ReportSizeEvent();