mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-07-04 23:31:19 +01:00
commit
5b2cb22a04
1 changed files with 9 additions and 8 deletions
|
@ -1082,16 +1082,17 @@ void GMainWindow::OnAppFocusStateChanged(Qt::ApplicationState state) {
|
|||
state != Qt::ApplicationActive) {
|
||||
LOG_DEBUG(Frontend, "ApplicationState unusual flag: {} ", state);
|
||||
}
|
||||
if (ui->action_Pause->isEnabled() &&
|
||||
if (emulation_running) {
|
||||
if (emu_thread->IsRunning() &&
|
||||
(state & (Qt::ApplicationHidden | Qt::ApplicationInactive))) {
|
||||
auto_paused = true;
|
||||
OnPauseGame();
|
||||
} else if (emulation_running && !emu_thread->IsRunning() && auto_paused &&
|
||||
state == Qt::ApplicationActive) {
|
||||
} else if (!emu_thread->IsRunning() && auto_paused && state == Qt::ApplicationActive) {
|
||||
auto_paused = false;
|
||||
OnStartGame();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void GMainWindow::ConnectWidgetEvents() {
|
||||
connect(game_list, &GameList::BootGame, this, &GMainWindow::BootGame);
|
||||
|
|
Loading…
Reference in a new issue