aboutsummaryrefslogtreecommitdiff
path: root/engines/prince
diff options
context:
space:
mode:
authorlukaslw2014-11-08 19:41:26 +0100
committerlukaslw2014-11-08 19:44:06 +0100
commitccb051f0e37481161a8546f74e6e96e2013de9e9 (patch)
tree55a96c53af9fb5b477eee200b9cf2284fc50c925 /engines/prince
parent9f2c3d794e4594fd736b6130412c1685ea21afc9 (diff)
downloadscummvm-rg350-ccb051f0e37481161a8546f74e6e96e2013de9e9.tar.gz
scummvm-rg350-ccb051f0e37481161a8546f74e6e96e2013de9e9.tar.bz2
scummvm-rg350-ccb051f0e37481161a8546f74e6e96e2013de9e9.zip
PRINCE: Implement pauseEngineIntern() - pause and resume music in GMM
Diffstat (limited to 'engines/prince')
-rw-r--r--engines/prince/prince.cpp10
-rw-r--r--engines/prince/prince.h1
2 files changed, 11 insertions, 0 deletions
diff --git a/engines/prince/prince.cpp b/engines/prince/prince.cpp
index 00e1736c46..43ff218e1d 100644
--- a/engines/prince/prince.cpp
+++ b/engines/prince/prince.cpp
@@ -427,6 +427,16 @@ Common::Error PrinceEngine::run() {
return Common::kNoError;
}
+void PrinceEngine::pauseEngineIntern(bool pause) {
+ Engine::pauseEngineIntern(pause);
+ if (pause) {
+ _midiPlayer->pause();
+ }
+ else {
+ _midiPlayer->resume();
+ }
+}
+
bool AnimListItem::loadFromStream(Common::SeekableReadStream &stream) {
int32 pos = stream.pos();
diff --git a/engines/prince/prince.h b/engines/prince/prince.h
index 48491c63bd..15887b2de8 100644
--- a/engines/prince/prince.h
+++ b/engines/prince/prince.h
@@ -256,6 +256,7 @@ public:
virtual ~PrinceEngine();
virtual bool hasFeature(EngineFeature f) const;
+ virtual void pauseEngineIntern(bool pause);
virtual bool canSaveGameStateCurrently();
virtual bool canLoadGameStateCurrently();
virtual Common::Error saveGameState(int slot, const Common::String &desc);