Bug 1189622 part 1 - Ensure the in-fullscreen-change flag is set before calling the second phase. r=smaug

--HG--
extra : source : d296fe5d387c2d52d7a952871b9122df46b50b1f
This commit is contained in:
Xidorn Quan 2016-01-12 15:18:47 +11:00
Родитель f569fa65f9
Коммит 5e959008be
1 изменённых файлов: 7 добавлений и 0 удалений

Просмотреть файл

@ -6094,6 +6094,13 @@ nsGlobalWindow::SetFullscreenInternal(FullscreenReason aReason,
}
}
// If we didn't setup the widget, we may need to manually set this
// flag, or the assertion in FinishFullscreenChange is violated.
if (nsCOMPtr<nsIPresShell> presShell = mDocShell->GetPresShell()) {
if (!presShell->IsInFullscreenChange()) {
presShell->SetIsInFullscreenChange(true);
}
}
FinishFullscreenChange(aFullScreen);
return NS_OK;
}