зеркало из https://github.com/mozilla/pjs.git
make GetParent return null if the window has been destroyed. this prevents mistaken attempts to access a destroyed window's parent. bug 92291 r=hyatt,saari
This commit is contained in:
Родитель
ad8345e05c
Коммит
7fc84a6001
|
@ -1270,6 +1270,11 @@ nsIWidget* nsWindow::GetParent(void)
|
|||
// a HWND which is not associated with a nsIWidget.
|
||||
return nsnull;
|
||||
}
|
||||
/* If this widget has already been destroyed, pretend we have no parent.
|
||||
This corresponds to code in Destroy which removes the destroyed
|
||||
widget from its parent's child list. */
|
||||
if (mIsDestroying || mOnDestroyCalled)
|
||||
return nsnull;
|
||||
|
||||
|
||||
nsWindow* widget = nsnull;
|
||||
|
|
Загрузка…
Ссылка в новой задаче