mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-13 02:08:49 +12:00
Move display sleep functions to emu callbacks
This commit is contained in:
parent
87db82cacd
commit
8d801dadc4
8 changed files with 38 additions and 48 deletions
|
@ -51,8 +51,6 @@
|
|||
|
||||
#include "Utilities/JIT.h"
|
||||
|
||||
#include "display_sleep_control.h"
|
||||
|
||||
#include "Emu/IPC_socket.h"
|
||||
|
||||
#if defined(HAVE_VULKAN)
|
||||
|
@ -2506,7 +2504,7 @@ void Emulator::Run(bool start_playtime)
|
|||
|
||||
if (g_cfg.misc.prevent_display_sleep)
|
||||
{
|
||||
disable_display_sleep();
|
||||
Emu.GetCallbacks().enable_display_sleep(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2791,7 +2789,7 @@ bool Emulator::Pause(bool freeze_emulation, bool show_resume_message)
|
|||
}
|
||||
|
||||
// Always Enable display sleep, not only if it was prevented.
|
||||
enable_display_sleep();
|
||||
Emu.GetCallbacks().enable_display_sleep(true);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -2888,7 +2886,7 @@ void Emulator::Resume()
|
|||
|
||||
if (g_cfg.misc.prevent_display_sleep)
|
||||
{
|
||||
disable_display_sleep();
|
||||
Emu.GetCallbacks().enable_display_sleep(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3798,7 +3796,7 @@ void Emulator::Kill(bool allow_autoexit, bool savestate, savestate_stage* save_s
|
|||
GetCallbacks().on_stop();
|
||||
|
||||
// Always Enable display sleep, not only if it was prevented.
|
||||
enable_display_sleep();
|
||||
Emu.GetCallbacks().enable_display_sleep(true);
|
||||
|
||||
if (allow_autoexit)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue