Use a std::set for MIDI device models so the combo is sorted and the user can find...
[ardour.git] / libs / ardour / midi_patch_manager.cc
index ac57ae93c69d799a0be53dea910e7d08b010b232..717f290944c4bcde20c6764588979acf98cae053 100644 (file)
@@ -83,7 +83,7 @@ MidiPatchManager::add_session_patches ()
                        _documents[device->first] = document;
                        // build a list of all master devices from all documents
                        _master_devices_by_model[device->first] = device->second;
-                       _all_models.push_back(device->first);
+                       _all_models.insert(device->first);
 
                        // make sure there are no double model names
                        // TODO: handle this gracefully.
@@ -119,7 +119,7 @@ MidiPatchManager::refresh()
                        _documents[device->first] = document;
                        // build a list of all master devices from all documents
                        _master_devices_by_model[device->first] = device->second;
-                       _all_models.push_back(device->first);
+                       _all_models.insert(device->first);
 
                        // make sure there are no double model names
                        // TODO: handle this gracefully.