summaryrefslogtreecommitdiff
path: root/libs/midi++2
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2013-01-19 19:25:06 +0000
committerDavid Robillard <d@drobilla.net>2013-01-19 19:25:06 +0000
commit2d9a15087bad6dfaeedd259b2fe948627d3b5ffb (patch)
tree507a37f482510281ba7ee18a7c1e6dc1c012a1c2 /libs/midi++2
parentca41354e466333425ae7ed5d99486ca5b5a125be (diff)
Use a std::set for MIDI device models so the combo is sorted and the user can find things.
git-svn-id: svn://localhost/ardour2/branches/3.0@13902 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/midi++2')
-rw-r--r--libs/midi++2/midi++/midnam_patch.h2
-rw-r--r--libs/midi++2/midnam_patch.cc4
2 files changed, 3 insertions, 3 deletions
diff --git a/libs/midi++2/midi++/midnam_patch.h b/libs/midi++2/midi++/midnam_patch.h
index a759e503dd..e218eeeedd 100644
--- a/libs/midi++2/midi++/midnam_patch.h
+++ b/libs/midi++2/midi++/midnam_patch.h
@@ -333,7 +333,7 @@ private:
class MasterDeviceNames
{
public:
- typedef std::list<std::string> Models;
+ typedef std::set<std::string> Models;
/// maps name to CustomDeviceMode
typedef std::map<std::string, boost::shared_ptr<CustomDeviceMode> > CustomDeviceModes;
typedef std::list<std::string> CustomDeviceModeNames;
diff --git a/libs/midi++2/midnam_patch.cc b/libs/midi++2/midnam_patch.cc
index 3509d1e021..82fc579d1a 100644
--- a/libs/midi++2/midnam_patch.cc
+++ b/libs/midi++2/midnam_patch.cc
@@ -490,7 +490,7 @@ MasterDeviceNames::set_state(const XMLTree& tree, const XMLNode&)
assert(contents.size() == 1);
XMLNode * content = *(contents.begin());
assert(content->is_content());
- _models.push_back(content->content());
+ _models.insert(content->content());
}
// CustomDeviceModes
@@ -634,7 +634,7 @@ MIDINameDocument::set_state (const XMLTree& tree, const XMLNode&)
std::pair<std::string, boost::shared_ptr<MasterDeviceNames> >
(*model, master_device_names));
- _all_models.push_back(*model);
+ _all_models.insert(*model);
}
}