From bdd960cd99e41f51d9a8b98f27fe231ce1ed15db Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Fri, 21 Apr 2017 02:56:29 +0200 Subject: [PATCH] Update preferences when Ctrl-surfaces change with session. --- gtk2_ardour/rc_option_editor.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gtk2_ardour/rc_option_editor.cc b/gtk2_ardour/rc_option_editor.cc index 84034ae633..f4fbcc4f76 100644 --- a/gtk2_ardour/rc_option_editor.cc +++ b/gtk2_ardour/rc_option_editor.cc @@ -1374,7 +1374,7 @@ class ControlSurfacesOptions : public OptionEditorMiniPage if (!(*i)->mandatory) { TreeModel::Row r = *_store->append (); r[_model.name] = (*i)->name; - r[_model.enabled] = ((*i)->protocol || (*i)->requested); + r[_model.enabled] = 0 != (*i)->protocol; r[_model.protocol_info] = *i; } } @@ -1391,8 +1391,9 @@ class ControlSurfacesOptions : public OptionEditorMiniPage if ((*x)[_model.protocol_info] == cpi) { _ignore_view_change++; - (*x)[_model.enabled] = (cpi->protocol || cpi->requested); + (*x)[_model.enabled] = 0 != cpi->protocol; _ignore_view_change--; + selection_changed (); // update sensitivity break; } }