mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-20 05:45:21 +00:00
Savestates: Fix restart when suspend mode is off
Add a new menu button for explicit exit (mostly for debug purposes)
This commit is contained in:
parent
01ee119c59
commit
f19744ae88
4 changed files with 34 additions and 4 deletions
|
|
@ -57,6 +57,7 @@
|
|||
#include "Emu/vfs_config.h"
|
||||
#include "Emu/System.h"
|
||||
#include "Emu/system_utils.hpp"
|
||||
#include "Emu/system_config.h"
|
||||
|
||||
#include "Crypto/unpkg.h"
|
||||
#include "Crypto/unself.h"
|
||||
|
|
@ -2395,6 +2396,21 @@ void main_window::CreateConnects()
|
|||
connect(ui->actionCreate_Savestate, &QAction::triggered, this, []()
|
||||
{
|
||||
gui_log.notice("User triggered savestate creation from utilities.");
|
||||
|
||||
if (!g_cfg.savestate.suspend_emu)
|
||||
{
|
||||
Emu.after_kill_callback = []()
|
||||
{
|
||||
Emu.Restart();
|
||||
};
|
||||
}
|
||||
|
||||
Emu.Kill(false, true);
|
||||
});
|
||||
|
||||
connect(ui->actionCreate_Savestate_And_Exit, &QAction::triggered, this, []()
|
||||
{
|
||||
gui_log.notice("User triggered savestate creation and emulation stop from utilities.");
|
||||
Emu.Kill(false, true);
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue