13
0

remove unnecessary code

If there's no GUI property for the MIDNAM model name, and the plugin has no MIDNAM, there's no reason to set the property to the default

It will pick up the default ("Generic") during update_patch_selector() calling into model_changed
This commit is contained in:
Paul Davis 2020-02-11 14:16:47 -07:00
parent ca28404a2a
commit 9d60197ffb

View File

@ -255,13 +255,6 @@ MidiTimeAxisView::set_route (boost::shared_ptr<Route> rt)
} }
} }
if (gui_property (X_("midnam-model-name")).empty()) {
boost::shared_ptr<PluginInsert> pi = boost::dynamic_pointer_cast<PluginInsert> (_route->the_instrument ());
if (!pi || !pi->plugin ()->has_midnam ()) {
set_gui_property (X_("midnam-model-name"), DEFAULT_MIDNAM_MODEL);
}
}
if (gui_property (X_("midnam-custom-device-mode")).empty()) { if (gui_property (X_("midnam-custom-device-mode")).empty()) {
boost::shared_ptr<MIDI::Name::MasterDeviceNames> device_names = get_device_names(); boost::shared_ptr<MIDI::Name::MasterDeviceNames> device_names = get_device_names();
if (device_names) { if (device_names) {