diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2013-04-24 00:33:40 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2013-04-24 00:33:40 +0200 |
commit | 25b7c03c47f8558e4759b0845eb367b580f3f9b4 (patch) | |
tree | 64e7b84cbdd7e40c3c1f6cf47e9ee16d04a5cdae /src | |
parent | 49a03c5d6379622c301f8c5c7eeb7018c2a69354 (diff) |
Fixed missing midimap filename in GUI.
Diffstat (limited to 'src')
-rw-r--r-- | src/drumgizmo.cc | 11 | ||||
-rw-r--r-- | src/drumgizmo.h | 1 |
2 files changed, 9 insertions, 3 deletions
diff --git a/src/drumgizmo.cc b/src/drumgizmo.cc index 83bd747..32ad66e 100644 --- a/src/drumgizmo.cc +++ b/src/drumgizmo.cc @@ -204,8 +204,15 @@ void DrumGizmo::handleEngineEvents() case Message::EngineSettingsMessage: { DEBUG(msg, "got EngineSettingsMessage message."); + + std::string mmapfile; + if(ie->isMidiEngine()) { + AudioInputEngineMidi *aim = (AudioInputEngineMidi*)ie; + mmapfile = aim->midimapFile(); + } + EngineSettingsMessage *msg = new EngineSettingsMessage(); - msg->midimapfile = midimapfile; + msg->midimapfile = mmapfile; msg->midimap_loaded = true; msg->drumkitfile = drumkitfile(); msg->drumkit_loaded = true; @@ -586,7 +593,7 @@ bool DrumGizmo::setConfigString(std::string cfg) } std::string newmidimap = p.value("midimapfile"); - if(midimapfile != newmidimap && newmidimap != "") { + if(newmidimap != "") { //midimapfile = newmidimap; LoadMidimapMessage *msg = new LoadMidimapMessage(); msg->midimapfile = newmidimap; diff --git a/src/drumgizmo.h b/src/drumgizmo.h index c03fd95..ffb9b07 100644 --- a/src/drumgizmo.h +++ b/src/drumgizmo.h @@ -67,7 +67,6 @@ public: std::string configString(); bool setConfigString(std::string cfg); - std::string midimapfile; std::string kitfile; /* |