summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authorLen Ovens <len@ovenwerks.net>2015-11-26 06:55:25 -0800
committerLen Ovens <len@ovenwerks.net>2015-11-26 06:55:25 -0800
commit3893f62657d0d636c6cf9f3c77797e7a0cf968d5 (patch)
tree234e185ac54d9c82730089db7c8c16bf94b3f8bb /libs
parentd138f8981d063a58b49be20fe890748591e81c2f (diff)
Mackie Control: Disable Selected group in User/Selected view mode to allow individual adjustment.
Diffstat (limited to 'libs')
-rw-r--r--libs/surfaces/mackie/mackie_control_protocol.cc46
1 files changed, 34 insertions, 12 deletions
diff --git a/libs/surfaces/mackie/mackie_control_protocol.cc b/libs/surfaces/mackie/mackie_control_protocol.cc
index 4db555b837..9e05dbc5a3 100644
--- a/libs/surfaces/mackie/mackie_control_protocol.cc
+++ b/libs/surfaces/mackie/mackie_control_protocol.cc
@@ -51,6 +51,7 @@
#include "ardour/panner.h"
#include "ardour/panner_shell.h"
#include "ardour/route.h"
+#include "ardour/route_group.h"
#include "ardour/session.h"
#include "ardour/tempo.h"
#include "ardour/track.h"
@@ -290,38 +291,59 @@ MackieControlProtocol::get_sorted_routes()
switch (_view_mode) {
case Mixer:
- sorted.push_back (*it);
+ if (route->route_group()) {
+ route->route_group()->set_active (true, this);
+ }
+ sorted.push_back (route);
remote_ids.insert (route->remote_control_id());
break;
case AudioTracks:
- if (is_audio_track(*it)) {
- sorted.push_back (*it);
+ if (is_audio_track(route)) {
+ if (route->route_group()) {
+ route->route_group()->set_active (true, this);
+ }
+ sorted.push_back (route);
remote_ids.insert (route->remote_control_id());
}
break;
case Busses:
- if (!is_track(*it)) {
- sorted.push_back (*it);
+ if (!is_track(route)) {
+ if (route->route_group()) {
+ route->route_group()->set_active (true, this);
+ }
+ sorted.push_back (route);
remote_ids.insert (route->remote_control_id());
}
break;
- case MidiTracks: // for now aux and buss are same
- if (is_midi_track(*it)) {
- sorted.push_back (*it);
+ case MidiTracks:
+ if (is_midi_track(route)) {
+ if (route->route_group()) {
+ route->route_group()->set_active (true, this);
+ }
+ sorted.push_back (route);
remote_ids.insert (route->remote_control_id());
}
break;
case Plugins:
break;
case Auxes: // for now aux and buss are same
- if (!is_track(*it)) {
- sorted.push_back (*it);
+ if (!is_track(route)) {
+ if (route->route_group()) {
+ route->route_group()->set_active (true, this);
+ }
+ sorted.push_back (route);
remote_ids.insert (route->remote_control_id());
}
break;
case Selected: // For example: a group
- if (selected(*it)) {
- sorted.push_back (*it);
+ if (selected(route)) {
+ /* Selected may be a group in which case we want to
+ * control each track separately.
+ */
+ if (route->route_group()) {
+ route->route_group()->set_active (false, this);
+ }
+ sorted.push_back (route);
remote_ids.insert (route->remote_control_id());
}
break;