the arguments to this function can be null-pointers, bug 124986 r=karnaze sr=attinasi

git-svn-id: svn://10.0.0.236/trunk@114419 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bernd.mielke%snafu.de 2002-02-13 20:07:56 +00:00
parent 8b23e2ee5b
commit 1c56c63b81

View File

@ -304,13 +304,17 @@ NS_IMETHODIMP nsWebBrowserChrome::GetDimensions(PRUint32 aFlags, PRInt32 *aX, PR
mBrowserWindow->GetPositionAndSize(&x, &y, &cx, &cy);
if (aFlags & DIM_FLAGS_POSITION)
{
*aX = x;
*aY = y;
if(aX)
*aX = x;
if(aY)
*aY = y;
}
if (aFlags & DIM_FLAGS_SIZE_INNER || aFlags & DIM_FLAGS_SIZE_OUTER)
{
*aCX = cx;
*aCY = cy;
if(aCX)
*aCX = cx;
if(aCY)
*aCY = cy;
}
return NS_OK;
}