diff options
Diffstat (limited to 'gtk2_ardour/rc_option_editor.cc')
-rw-r--r-- | gtk2_ardour/rc_option_editor.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gtk2_ardour/rc_option_editor.cc b/gtk2_ardour/rc_option_editor.cc index a3796a6746..c4c75ea6d7 100644 --- a/gtk2_ardour/rc_option_editor.cc +++ b/gtk2_ardour/rc_option_editor.cc @@ -107,6 +107,7 @@ private: MIDI::Manager::PortList const & ports = MIDI::Manager::instance()->get_midi_ports (); _store->clear (); + port_connections.drop_connections (); for (MIDI::Manager::PortList::const_iterator i = ports.begin(); i != ports.end(); ++i) { @@ -116,7 +117,7 @@ private: if ((*i)->input()) { r[_model.online] = !(*i)->input()->offline(); - (*i)->input()->OfflineStatusChanged.connect (sigc::bind (sigc::mem_fun (*this, &MIDIPorts::port_offline_changed), (*i))); + (*i)->input()->OfflineStatusChanged.connect (port_connections, boost::bind (&MIDIPorts::port_offline_changed, this, (*i))); r[_model.trace_input] = (*i)->input()->tracing(); } @@ -216,6 +217,7 @@ private: ComboBoxText _mmc_combo; ComboBoxText _mpc_combo; list<ComboOption<string>* > _port_combos; + PBD::ScopedConnectionList port_connections; }; |