[Scummvm-git-logs] scummvm master -> f3d9d88f58d38fedbf6d65d825d6183013086898
dreammaster
dreammaster at scummvm.org
Tue Nov 8 02:27:02 CET 2016
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
d85f56e1fe TITANIC: Fix showing Continue dialog when more than 5 saves present
f3d9d88f58 TITANIC: Fix stopping all playing sounds when loading a savegame
Commit: d85f56e1fe66752a747b92c92a44161b2ff56349
https://github.com/scummvm/scummvm/commit/d85f56e1fe66752a747b92c92a44161b2ff56349
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2016-11-07T20:26:27-05:00
Commit Message:
TITANIC: Fix showing Continue dialog when more than 5 saves present
Changed paths:
engines/titanic/continue_save_dialog.cpp
diff --git a/engines/titanic/continue_save_dialog.cpp b/engines/titanic/continue_save_dialog.cpp
index 39b7d19..0982cab 100644
--- a/engines/titanic/continue_save_dialog.cpp
+++ b/engines/titanic/continue_save_dialog.cpp
@@ -54,9 +54,10 @@ CContinueSaveDialog::~CContinueSaveDialog() {
}
void CContinueSaveDialog::addSavegame(int slot, const CString &name) {
- assert(_saves.size() < SAVEGAME_SLOTS_COUNT);
- _slotNames[_saves.size()].setText(name);
- _saves.push_back(SaveEntry(slot, name));
+ if (_saves.size() < SAVEGAME_SLOTS_COUNT) {
+ _slotNames[_saves.size()].setText(name);
+ _saves.push_back(SaveEntry(slot, name));
+ }
}
Rect CContinueSaveDialog::getSlotBounds(int index) {
Commit: f3d9d88f58d38fedbf6d65d825d6183013086898
https://github.com/scummvm/scummvm/commit/f3d9d88f58d38fedbf6d65d825d6183013086898
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2016-11-07T20:26:51-05:00
Commit Message:
TITANIC: Fix stopping all playing sounds when loading a savegame
Changed paths:
engines/titanic/sound/qmixer.cpp
diff --git a/engines/titanic/sound/qmixer.cpp b/engines/titanic/sound/qmixer.cpp
index ecc0bbc..b3910f8 100644
--- a/engines/titanic/sound/qmixer.cpp
+++ b/engines/titanic/sound/qmixer.cpp
@@ -60,12 +60,19 @@ void QMixer::qsWaveMixFreeWave(Audio::SoundHandle &handle) {
}
void QMixer::qsWaveMixFlushChannel(int iChannel, uint flags) {
- Common::List<SoundEntry>::iterator i;
- Common::List<SoundEntry> &sounds = _channels[iChannel]._sounds;
- for (i = sounds.begin(); i != sounds.end(); ++i)
- _mixer->stopHandle((*i)._soundHandle);
-
- sounds.clear();
+ if (flags & QMIX_OPENALL) {
+ // Ignore channel, and flush all the channels
+ for (uint idx = 0; idx < _channels.size(); ++idx)
+ qsWaveMixFlushChannel(idx, 0);
+ } else {
+ // Flush the specified channel
+ Common::List<SoundEntry>::iterator i;
+ Common::List<SoundEntry> &sounds = _channels[iChannel]._sounds;
+ for (i = sounds.begin(); i != sounds.end(); ++i)
+ _mixer->stopHandle((*i)._soundHandle);
+
+ sounds.clear();
+ }
}
void QMixer::qsWaveMixSetPanRate(int iChannel, uint flags, uint rate) {
More information about the Scummvm-git-logs
mailing list