Commit c2ba2706 authored by Edgar Chen's avatar Edgar Chen Committed by Pier Angelo Vendrame
Browse files

Bug 1828259 - Close XUL popup when entering/exiting fullscreen; r=smaug

parent 9d7218aa
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -3018,6 +3018,9 @@ void AppWindow::FullscreenChanged(bool aInFullscreen) {

void AppWindow::FinishFullscreenChange(bool aInFullscreen) {
  mFullscreenChangeState = FullscreenChangeState::NotChanging;
  if (nsXULPopupManager* pm = nsXULPopupManager::GetInstance()) {
    pm->Rollup({});
  }
  if (mDocShell) {
    if (nsCOMPtr<nsPIDOMWindowOuter> ourWindow = mDocShell->GetWindow()) {
      ourWindow->FinishFullscreenChange(aInFullscreen);