don't move or resize windows that belong to embedding apps

This commit is contained in:
pierre%netscape.com 1999-02-03 02:04:15 +00:00
parent 8489e73f9b
commit 8ab85d5e8a

View File

@ -237,6 +237,8 @@ NS_IMETHODIMP nsMacWindow::Show(PRBool bState)
//
//-------------------------------------------------------------------------
NS_IMETHODIMP nsMacWindow::Move(PRUint32 aX, PRUint32 aY)
{
if (mWindowMadeHere)
{
Rect screenRect = (**::GetGrayRgn()).rgnBBox;
@ -266,6 +268,7 @@ NS_IMETHODIMP nsMacWindow::Move(PRUint32 aX, PRUint32 aY)
if ((macPoint.h != aX) || (macPoint.v != aY)) {
::MoveWindow(mWindowPtr, aX, aY, false);
}
}
return NS_OK;
}
@ -276,8 +279,8 @@ NS_IMETHODIMP nsMacWindow::Move(PRUint32 aX, PRUint32 aY)
//-------------------------------------------------------------------------
NS_IMETHODIMP nsMacWindow::Resize(PRUint32 aWidth, PRUint32 aHeight, PRBool aRepaint)
{
// move the window if it has not been moved yet
// (ie. if this function isn't called in response to a GrowWindow event)
if (mWindowMadeHere)
{
Rect macRect = mWindowPtr->portRect;
#ifdef WINDOW_SIZE_TWEAKING
macRect.right ++;
@ -292,6 +295,7 @@ NS_IMETHODIMP nsMacWindow::Resize(PRUint32 aWidth, PRUint32 aHeight, PRBool aRep
::SizeWindow(mWindowPtr, aWidth, aHeight, aRepaint);
#endif
}
}
nsWindow::Resize(aWidth, aHeight, aRepaint);
return NS_OK;
}