Skip to content

Commit

Permalink
Qt: Use main window geometry for temporary window
Browse files Browse the repository at this point in the history
When displaying the confirm popup when fullscreen.
  • Loading branch information
stenzek committed Nov 21, 2023
1 parent b79edf1 commit f18964a
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions pcsx2-qt/MainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2022,7 +2022,10 @@ std::optional<WindowInfo> MainWindow::acquireRenderWindow(bool recreate_window,
}
else
{
restoreDisplayWindowGeometryFromConfig();
if (m_is_temporarily_windowed && g_emu_thread->shouldRenderToMain())
container->setGeometry(geometry());
else
restoreDisplayWindowGeometryFromConfig();
container->showNormal();
}

Expand Down Expand Up @@ -2098,7 +2101,7 @@ void MainWindow::createDisplayWidget(bool fullscreen, bool render_to_main)
// and positioning has no effect anyway.
if (!s_use_central_widget)
{
if ((isVisible() || m_is_temporarily_windowed) && g_emu_thread->shouldRenderToMain())
if (isVisible() && g_emu_thread->shouldRenderToMain())
container->move(pos());
else
restoreDisplayWindowGeometryFromConfig();
Expand All @@ -2108,7 +2111,10 @@ void MainWindow::createDisplayWidget(bool fullscreen, bool render_to_main)
}
else if (!render_to_main)
{
restoreDisplayWindowGeometryFromConfig();
if (m_is_temporarily_windowed && g_emu_thread->shouldRenderToMain())
container->setGeometry(geometry());
else
restoreDisplayWindowGeometryFromConfig();
container->showNormal();
}
else if (s_use_central_widget)
Expand Down

0 comments on commit f18964a

Please sign in to comment.