Bug 1307212 - Stop warning about z-levels. r=froydnj

MozReview-Commit-ID: 2OughbymcrU
This commit is contained in:
Eric Rahm 2017-05-23 15:14:07 -07:00
parent 0bd37c1ea1
commit 0b39451aa9

View File

@ -613,12 +613,10 @@ nsWindowMediator::GetZLevel(nsIXULWindow *aWindow, uint32_t *_retval)
{
NS_ENSURE_ARG_POINTER(_retval);
*_retval = nsIXULWindow::normalZ;
// This can fail during window destruction.
nsWindowInfo *info = GetInfoFor(aWindow);
if (info) {
*_retval = info->mZLevel;
} else {
NS_WARNING("getting z level of unregistered window");
// this goes off during window destruction
}
return NS_OK;
}