mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2025-02-17 03:15:39 +00:00
Merge pull request #2251 from CookiePLMonster/fullscreen-ui-exit-crash
Fix a crash when shutting down emulation from the Hardcore mode confirmation prompt
This commit is contained in:
commit
0e01a65e78
|
@ -1204,6 +1204,7 @@ static bool ConfirmChallengeModeEnable()
|
||||||
if (!s_host_interface->ConfirmMessage(message))
|
if (!s_host_interface->ConfirmMessage(message))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
SaveAndApplySettings();
|
||||||
s_host_interface->PowerOffSystem(s_host_interface->ShouldSaveResumeState());
|
s_host_interface->PowerOffSystem(s_host_interface->ShouldSaveResumeState());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -2267,8 +2268,6 @@ void DrawSettingsWindow()
|
||||||
s_host_interface->RunLater([]() {
|
s_host_interface->RunLater([]() {
|
||||||
if (!ConfirmChallengeModeEnable())
|
if (!ConfirmChallengeModeEnable())
|
||||||
s_host_interface->GetSettingsInterface()->SetBoolValue("Cheevos", "Enabled", false);
|
s_host_interface->GetSettingsInterface()->SetBoolValue("Cheevos", "Enabled", false);
|
||||||
else
|
|
||||||
SaveAndApplySettings();
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2299,8 +2298,6 @@ void DrawSettingsWindow()
|
||||||
s_host_interface->RunLater([]() {
|
s_host_interface->RunLater([]() {
|
||||||
if (!ConfirmChallengeModeEnable())
|
if (!ConfirmChallengeModeEnable())
|
||||||
s_host_interface->GetSettingsInterface()->SetBoolValue("Cheevos", "ChallengeMode", false);
|
s_host_interface->GetSettingsInterface()->SetBoolValue("Cheevos", "ChallengeMode", false);
|
||||||
else
|
|
||||||
SaveAndApplySettings();
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue