diff options
author | Joost Peters | 2009-09-23 16:11:23 +0000 |
---|---|---|
committer | Joost Peters | 2009-09-23 16:11:23 +0000 |
commit | 6a5bd81599fbafe8edc92add8316eba74504e49d (patch) | |
tree | 57de3e785bdbe0dfa83ab38131f546a3a2f2a89d /backends/platform/psp/osys_psp.cpp | |
parent | 227e4e65df7093b2be9b45106b529761a13068dd (diff) | |
download | scummvm-rg350-6a5bd81599fbafe8edc92add8316eba74504e49d.tar.gz scummvm-rg350-6a5bd81599fbafe8edc92add8316eba74504e49d.tar.bz2 scummvm-rg350-6a5bd81599fbafe8edc92add8316eba74504e49d.zip |
PSP: improved suspend/resume support [patch from bluddy]
svn-id: r44276
Diffstat (limited to 'backends/platform/psp/osys_psp.cpp')
-rw-r--r-- | backends/platform/psp/osys_psp.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/backends/platform/psp/osys_psp.cpp b/backends/platform/psp/osys_psp.cpp index 78081db384..79804b3e18 100644 --- a/backends/platform/psp/osys_psp.cpp +++ b/backends/platform/psp/osys_psp.cpp @@ -35,6 +35,7 @@ #include "osys_psp.h" #include "trace.h" +#include "powerman.h" #include "backends/saves/psp/psp-saves.h" #include "backends/timer/default/default-timer.h" @@ -927,6 +928,13 @@ bool OSystem_PSP::processInput(Common::Event &event) { bool OSystem_PSP::pollEvent(Common::Event &event) { float nub_angle = -1; int x, y; + + // If we're polling for events, we should check for pausing the engine + // Pausing the engine is a necessary fix for games that use the timer for music synchronization + // recovering many hours later causes the game to crash. We're polling without mutexes since it's not critical to + // get it right now. + + PowerMan.pollPauseEngine(); sceCtrlSetSamplingCycle(0); sceCtrlSetSamplingMode(1); |