summaryrefslogtreecommitdiff
path: root/gtk2_ardour/port_matrix_column_labels.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2010-07-27 02:10:40 +0000
committerCarl Hetherington <carl@carlh.net>2010-07-27 02:10:40 +0000
commit9998ce310d81e0d16488a694902d296cde4a8ff7 (patch)
treecdb3c660c3a104a7447e5ab716bc401b4da0ebc9 /gtk2_ardour/port_matrix_column_labels.cc
parent43e4abb391863576f904e46029d22f26173678d0 (diff)
Remove some instances of erroneously-drawn bundle names.
git-svn-id: svn://localhost/ardour2/branches/3.0@7508 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/port_matrix_column_labels.cc')
-rw-r--r--gtk2_ardour/port_matrix_column_labels.cc14
1 files changed, 12 insertions, 2 deletions
diff --git a/gtk2_ardour/port_matrix_column_labels.cc b/gtk2_ardour/port_matrix_column_labels.cc
index fe5158588f..ac4e1fef45 100644
--- a/gtk2_ardour/port_matrix_column_labels.cc
+++ b/gtk2_ardour/port_matrix_column_labels.cc
@@ -133,8 +133,18 @@ PortMatrixColumnLabels::render (cairo_t* cr)
PortGroup::BundleList const & bundles = _matrix->visible_columns()->bundles ();
for (PortGroup::BundleList::const_iterator i = bundles.begin (); i != bundles.end(); ++i) {
- Gdk::Color c = (*i)->has_colour ? (*i)->colour : get_a_bundle_colour (N);
- render_bundle_name (cr, background_colour (), c, x, 0, (*i)->bundle);
+ bool should_show_this_bundle = false;
+ for (uint32_t j = 0; j < (*i)->bundle->nchannels().n_total(); ++j) {
+ if (_matrix->should_show ((*i)->bundle->channel_type (j))) {
+ should_show_this_bundle = true;
+ break;
+ }
+ }
+
+ if (should_show_this_bundle) {
+ Gdk::Color c = (*i)->has_colour ? (*i)->colour : get_a_bundle_colour (N);
+ render_bundle_name (cr, background_colour (), c, x, 0, (*i)->bundle);
+ }
if (_matrix->show_only_bundles()) {
x += grid_spacing();