aboutsummaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorMax Horn2009-12-09 18:12:51 +0000
committerMax Horn2009-12-09 18:12:51 +0000
commitc8873d8492ef8ae288e870b37c1c85f3b291d62c (patch)
treee9902f85422741542ea12f21c17824eab542a5fe /sound
parent84f3c98fad7d351611c879dddc86cd309b4f5281 (diff)
downloadscummvm-rg350-c8873d8492ef8ae288e870b37c1c85f3b291d62c.tar.gz
scummvm-rg350-c8873d8492ef8ae288e870b37c1c85f3b291d62c.tar.bz2
scummvm-rg350-c8873d8492ef8ae288e870b37c1c85f3b291d62c.zip
Changed MidiDriver::createMidi to take a MidiDriverType instead of an int
svn-id: r46316
Diffstat (limited to 'sound')
-rw-r--r--sound/mididrv.cpp5
-rw-r--r--sound/mididrv.h2
2 files changed, 4 insertions, 3 deletions
diff --git a/sound/mididrv.cpp b/sound/mididrv.cpp
index c7e7b757ba..1e721e9086 100644
--- a/sound/mididrv.cpp
+++ b/sound/mididrv.cpp
@@ -224,7 +224,7 @@ MidiDriverType MidiDriver::detectMusicDriver(int flags) {
return musicDriver;
}
-MidiDriver *MidiDriver::createMidi(int midiDriver) {
+MidiDriver *MidiDriver::createMidi(MidiDriverType midiDriver) {
switch (midiDriver) {
case MD_NULL: return MidiDriver_NULL_create();
@@ -280,8 +280,9 @@ MidiDriver *MidiDriver::createMidi(int midiDriver) {
#if defined(__amigaos4__)
case MD_CAMD: return MidiDriver_CAMD_create();
#endif
+ default:
+ error("Invalid midi driver selected");
}
- error("Invalid midi driver selected");
return NULL;
}
diff --git a/sound/mididrv.h b/sound/mididrv.h
index 10813f7300..3a03759f76 100644
--- a/sound/mididrv.h
+++ b/sound/mididrv.h
@@ -139,7 +139,7 @@ public:
*/
static const MidiDriverDescription *getAvailableMidiDrivers();
- static MidiDriver *createMidi(int midiDriver);
+ static MidiDriver *createMidi(MidiDriverType midiDriver);
static MidiDriverType detectMusicDriver(int flags);