diff options
author | Carl Hetherington <carl@carlh.net> | 2009-07-17 14:21:54 +0000 |
---|---|---|
committer | Carl Hetherington <carl@carlh.net> | 2009-07-17 14:21:54 +0000 |
commit | 748ad24ace7a37059b6812a1f9f0145d4725ba66 (patch) | |
tree | 162026ac28a6331013f37b0ee1d8cbbb46a08300 /gtk2_ardour/port_matrix_column_labels.cc | |
parent | be40312e01ea36e1aaa86cae8551e42353849bc2 (diff) |
Small optimisation. Fix mouseover highlighting in the port matrix.
git-svn-id: svn://localhost/ardour2/branches/3.0@5369 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/port_matrix_column_labels.cc')
-rw-r--r-- | gtk2_ardour/port_matrix_column_labels.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/gtk2_ardour/port_matrix_column_labels.cc b/gtk2_ardour/port_matrix_column_labels.cc index e630dec4c0..92affb1f31 100644 --- a/gtk2_ardour/port_matrix_column_labels.cc +++ b/gtk2_ardour/port_matrix_column_labels.cc @@ -413,8 +413,9 @@ PortMatrixColumnLabels::channel_x (ARDOUR::BundleChannel const &bc) const { uint32_t n = 0; - PortGroup::BundleList::const_iterator i = _matrix->columns()->bundles().begin(); - while (i != _matrix->columns()->bundles().end() && i->bundle != bc.bundle) { + PortGroup::BundleList const & b = _matrix->columns()->bundles (); + PortGroup::BundleList::const_iterator i = b.begin(); + while (i != b.end() && i->bundle != bc.bundle) { if (_matrix->show_only_bundles()) { n += 1; } else { @@ -426,7 +427,7 @@ PortMatrixColumnLabels::channel_x (ARDOUR::BundleChannel const &bc) const if (!_matrix->show_only_bundles()) { n += bc.channel; } - + return n * column_width(); } |