mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2026-11-02 04:04:56 +00:00
[desktop] queue FirstFrameDisplayed to fix loading screen race (#4536)
Signed-off-by: crueter <crueter@eden-emu.dev> - [x] I have read and followed the [Contribution Guidelines](https://git.eden-emu.dev/eden-emu/eden/src/branch/master/CONTRIBUTING.md#code-contributions). - [x] I have read and followed the [AI Policy](https://git.eden-emu.dev/eden-emu/eden/src/branch/master/docs/policies/AI.md). - [x] I have read and followed the [Coding Guidelines](https://git.eden-emu.dev/eden-emu/eden/src/branch/master/docs/policies/Coding.md) to the best of my ability. ------------------- Authored-by: Bitekiyo <334587657+Bitekiyo@users.noreply.github.com> Co-authored-by: Bitekiyo <334587657+Bitekiyo@users.noreply.github.com> Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/4536
This commit is contained in:
@@ -131,7 +131,8 @@ GRenderWindow::GRenderWindow(MainWindow* parent,
|
||||
strict_context_required = QGuiApplication::platformName() == QStringLiteral("wayland") ||
|
||||
QGuiApplication::platformName() == QStringLiteral("wayland-egl");
|
||||
|
||||
connect(this, &GRenderWindow::FirstFrameDisplayed, parent, &MainWindow::OnLoadComplete);
|
||||
connect(this, &GRenderWindow::FirstFrameDisplayed, parent, &MainWindow::OnLoadComplete,
|
||||
Qt::QueuedConnection);
|
||||
connect(this, &GRenderWindow::ExecuteProgramSignal, parent, &MainWindow::OnExecuteProgram,
|
||||
Qt::QueuedConnection);
|
||||
connect(this, &GRenderWindow::ExitSignal, parent, &MainWindow::OnExit, Qt::QueuedConnection);
|
||||
|
||||
@@ -3147,6 +3147,10 @@ bool MainWindow::ConfirmShutdownGame() {
|
||||
|
||||
void MainWindow::OnLoadComplete() {
|
||||
loading_screen->OnLoadComplete();
|
||||
if (emulation_running) {
|
||||
render_window->show();
|
||||
render_window->setFocus();
|
||||
}
|
||||
|
||||
perf_overlay = new PerformanceOverlay(this);
|
||||
perf_overlay->setVisible(ui->action_Show_Performance_Overlay->isChecked());
|
||||
|
||||
Reference in New Issue
Block a user