summaryrefslogtreecommitdiff
path: root/libs/midi++2/midi++/midnam_patch.h
diff options
context:
space:
mode:
authorHans Baier <hansfbaier@googlemail.com>2008-12-09 07:42:19 +0000
committerHans Baier <hansfbaier@googlemail.com>2008-12-09 07:42:19 +0000
commit457f06855e30ebdfeae0a5dfe39cb8f52422a912 (patch)
tree6c72d2c8115072e51338aad868d2a07e9a598c24 /libs/midi++2/midi++/midnam_patch.h
parent42db44c1939410aab15eb3c0d08f6026fb58b003 (diff)
* first working prototype of selecting instruments in the MIDI track header
* parsing patchfiles works git-svn-id: svn://localhost/ardour2/branches/3.0@4304 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/midi++2/midi++/midnam_patch.h')
-rw-r--r--libs/midi++2/midi++/midnam_patch.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/libs/midi++2/midi++/midnam_patch.h b/libs/midi++2/midi++/midnam_patch.h
index 2561d905eb..f9616ecf2d 100644
--- a/libs/midi++2/midi++/midnam_patch.h
+++ b/libs/midi++2/midi++/midnam_patch.h
@@ -24,6 +24,7 @@
#include <string>
#include <list>
#include <set>
+#include <map>
#include "pbd/stateful.h"
#include "midi++/event.h"
@@ -202,7 +203,8 @@ private:
class MIDINameDocument : public PBD::Stateful
{
public:
- typedef std::list<MasterDeviceNames> MasterDeviceNamesList;
+ // Maps Model names to MasterDeviceNames
+ typedef std::map<std::string, boost::shared_ptr<MasterDeviceNames> > MasterDeviceNamesList;
MIDINameDocument() {};
MIDINameDocument(const string &filename) : _document(XMLTree(filename)) { set_state(*_document.root()); };
@@ -211,13 +213,18 @@ public:
const string& author() const { return _author; }
void set_author(const string an_author) { _author = an_author; }
+ const MasterDeviceNamesList& master_device_names_by_model() const { return _master_device_names_list; }
+
+ const MasterDeviceNames::Models& all_models() const { return _all_models; }
+
XMLNode& get_state (void);
int set_state (const XMLNode& a_node);
private:
- string _author;
- MasterDeviceNamesList _master_device_names_list;
- XMLTree _document;
+ string _author;
+ MasterDeviceNamesList _master_device_names_list;
+ XMLTree _document;
+ MasterDeviceNames::Models _all_models;
};
}