summaryrefslogtreecommitdiff
path: root/libs/surfaces/launch_control_xl/launch_control_xl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libs/surfaces/launch_control_xl/launch_control_xl.cc')
-rw-r--r--libs/surfaces/launch_control_xl/launch_control_xl.cc13
1 files changed, 7 insertions, 6 deletions
diff --git a/libs/surfaces/launch_control_xl/launch_control_xl.cc b/libs/surfaces/launch_control_xl/launch_control_xl.cc
index f92d6125aa..dc2cd2bfa1 100644
--- a/libs/surfaces/launch_control_xl/launch_control_xl.cc
+++ b/libs/surfaces/launch_control_xl/launch_control_xl.cc
@@ -852,7 +852,7 @@ LaunchControlXL::switch_bank (uint32_t base)
boost::shared_ptr<Stripable> s[8];
uint32_t different = 0;
- int stripable_counter;
+ uint8_t stripable_counter;
if (LaunchControlXL::use_fader8master) {
stripable_counter = 7;
@@ -867,16 +867,17 @@ LaunchControlXL::switch_bank (uint32_t base)
}
}
- if (sl && sr) {
- write(sl->state_msg((base)));
- write(sr->state_msg((s[1] != 0)));
- }
-
if (!s[0]) {
/* not even the first stripable exists, do nothing */
return;
}
+ if (sl && sr) {
+ boost::shared_ptr<Stripable> next_base = session->get_remote_nth_stripable (base+8, PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::VCA));
+ write(sl->state_msg((base)));
+ write(sr->state_msg((next_base != 0)));
+ }
+
stripable_connections.drop_connections ();
for (int n = 0; n < stripable_counter; ++n) {