summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_routes.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2016-06-10 13:53:48 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2016-06-10 13:57:19 -0400
commitdf09d80bd39dbba9349cf8fac6cfb8a823c23df4 (patch)
tree6b2608e976f28f45f9e43e8e949b571cbb6e603d /gtk2_ardour/editor_routes.cc
parenta2fd790252b651fae8ccf2a3d7e35c3d7cf65a30 (diff)
EditorRoutes needs to respond to PropertyChanged(selected)
Diffstat (limited to 'gtk2_ardour/editor_routes.cc')
-rw-r--r--gtk2_ardour/editor_routes.cc33
1 files changed, 23 insertions, 10 deletions
diff --git a/gtk2_ardour/editor_routes.cc b/gtk2_ardour/editor_routes.cc
index dc41492dfd..4e97f75796 100644
--- a/gtk2_ardour/editor_routes.cc
+++ b/gtk2_ardour/editor_routes.cc
@@ -895,27 +895,40 @@ EditorRoutes::route_removed (TimeAxisView *tv)
void
EditorRoutes::route_property_changed (const PropertyChange& what_changed, boost::weak_ptr<Stripable> s)
{
+ if (!what_changed.contains (ARDOUR::Properties::hidden) && !what_changed.contains (ARDOUR::Properties::name)) {
+ return;
+ }
+
if (_adding_routes) {
return;
}
- if (what_changed.contains (ARDOUR::Properties::name)) {
+ boost::shared_ptr<Stripable> stripable = s.lock ();
- boost::shared_ptr<Stripable> stripable = s.lock ();
+ if (!stripable) {
+ return;
+ }
- if (!stripable) {
- return;
- }
+ TreeModel::Children rows = _model->children();
+ TreeModel::Children::iterator i;
+
+ for (i = rows.begin(); i != rows.end(); ++i) {
+
+ boost::shared_ptr<Stripable> ss = (*i)[_columns.stripable];
- TreeModel::Children rows = _model->children();
- TreeModel::Children::iterator i;
+ if (ss == stripable) {
- for (i = rows.begin(); i != rows.end(); ++i) {
- boost::shared_ptr<Stripable> ss = (*i)[_columns.stripable];
- if (ss == stripable) {
+ if (what_changed.contains (ARDOUR::Properties::name)) {
(*i)[_columns.text] = stripable->name();
break;
}
+
+ if (what_changed.contains (ARDOUR::Properties::hidden)) {
+ (*i)[_columns.visible] = !stripable->presentation_info().hidden();
+ redisplay ();
+ }
+
+ break;
}
}
}