summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libs/surfaces/launch_control_xl/launch_control_xl.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/libs/surfaces/launch_control_xl/launch_control_xl.cc b/libs/surfaces/launch_control_xl/launch_control_xl.cc
index 7d7ffff442..7c405df7ad 100644
--- a/libs/surfaces/launch_control_xl/launch_control_xl.cc
+++ b/libs/surfaces/launch_control_xl/launch_control_xl.cc
@@ -830,11 +830,6 @@ LaunchControlXL::switch_bank (uint32_t base)
SelectButton* sl = static_cast<SelectButton*>(id_controller_button_map[SelectLeft]);
SelectButton* sr = static_cast<SelectButton*>(id_controller_button_map[SelectRight]);
- if (sl && sr) {
- write(sl->state_msg( (base) ));
- write(sr->state_msg( !(base) ));
- }
-
/* work backwards so we can tell if we should actually switch banks */
boost::shared_ptr<Stripable> s[8];
@@ -847,6 +842,11 @@ 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;