summaryrefslogtreecommitdiff
path: root/src/drumgizmo.cc
diff options
context:
space:
mode:
authorjsc@umbraculum.org <jsc@umbraculum.org>2013-04-26 15:23:24 +0200
committerjsc@umbraculum.org <jsc@umbraculum.org>2013-04-26 15:23:24 +0200
commit3eeba619215dadb15a5fd992cba03bf760c23d3a (patch)
tree423450a0419b37fc9f3e8cf65c0a425e2e418ae7 /src/drumgizmo.cc
parent2eedb967d2a3f8026163bd182e973106e6846a13 (diff)
parent813d802443679a6f937a13680bc0ec3fb11a96b6 (diff)
Merge branch 'master' of http://git.drumgizmo.org/drumgizmo
Diffstat (limited to 'src/drumgizmo.cc')
-rw-r--r--src/drumgizmo.cc12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/drumgizmo.cc b/src/drumgizmo.cc
index 8ba45f5..943e852 100644
--- a/src/drumgizmo.cc
+++ b/src/drumgizmo.cc
@@ -201,22 +201,28 @@ void DrumGizmo::handleEngineEvents()
{
AudioInputEngineMidi *aim = (AudioInputEngineMidi*)ie;
LoadMidimapMessage *m = (LoadMidimapMessage*)msg;
- aim->loadMidiMap(m->midimapfile, kit.instruments);
+ bool ret = aim->loadMidiMap(m->midimapfile, kit.instruments);
+
+ LoadStatusMessageMidimap *ls = new LoadStatusMessageMidimap();
+ ls->success = ret;
+ sendGUIMessage(ls);
}
break;
case Message::EngineSettingsMessage:
{
DEBUG(msg, "got EngineSettingsMessage message.");
-
+ bool mmap_loaded = false;
std::string mmapfile;
if(ie->isMidiEngine()) {
AudioInputEngineMidi *aim = (AudioInputEngineMidi*)ie;
mmapfile = aim->midimapFile();
+ mmap_loaded = aim->isValid();
+
}
EngineSettingsMessage *msg = new EngineSettingsMessage();
msg->midimapfile = mmapfile;
- msg->midimap_loaded = true;
+ msg->midimap_loaded = mmap_loaded;
msg->drumkitfile = drumkitfile();
msg->drumkit_loaded = true;
msg->enable_velocity_modifier = Conf::enable_velocity_modifier;