diff options
author | Len Ovens <len@ovenwerks.net> | 2016-01-16 07:32:30 -0800 |
---|---|---|
committer | Len Ovens <len@ovenwerks.net> | 2016-01-16 07:32:30 -0800 |
commit | 92dba5bfa3870b56c1ddd9211abe82b16a1206a1 (patch) | |
tree | 9b613cec71a83bc4b70db7859bc878cc6375cf46 /libs | |
parent | 3f76b4ec17358170fc61fcf0ae8ddc393dd9d3d0 (diff) |
Mackie Control: Added hidden tracks view mode.
Diffstat (limited to 'libs')
-rw-r--r-- | libs/surfaces/mackie/mackie_control_protocol.cc | 34 | ||||
-rw-r--r-- | libs/surfaces/mackie/mackie_control_protocol.h | 1 | ||||
-rw-r--r-- | libs/surfaces/mackie/mcp_buttons.cc | 1 | ||||
-rw-r--r-- | libs/surfaces/mackie/surface.cc | 8 |
4 files changed, 31 insertions, 13 deletions
diff --git a/libs/surfaces/mackie/mackie_control_protocol.cc b/libs/surfaces/mackie/mackie_control_protocol.cc index 5f8c959867..97f96157d0 100644 --- a/libs/surfaces/mackie/mackie_control_protocol.cc +++ b/libs/surfaces/mackie/mackie_control_protocol.cc @@ -304,15 +304,18 @@ MackieControlProtocol::get_sorted_routes() } break; case AudioTracks: + if (route->route_group()) { + route->route_group()->set_active (true, this); + } if (is_audio_track(route) && !is_hidden(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 (route->route_group()) { + route->route_group()->set_active (true, this); + } if (Profile->get_mixbus()) { #ifdef MIXBUS if (route->mixbus()) { @@ -322,19 +325,16 @@ MackieControlProtocol::get_sorted_routes() #endif } else { if (!is_track(route) && !is_hidden(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: + if (route->route_group()) { + route->route_group()->set_active (true, this); + } if (is_midi_track(route) && !is_hidden(route)) { - if (route->route_group()) { - route->route_group()->set_active (true, this); - } sorted.push_back (route); remote_ids.insert (route->remote_control_id()); } @@ -342,10 +342,20 @@ MackieControlProtocol::get_sorted_routes() case Plugins: break; case Auxes: // in ardour, for now aux and buss are same. for mixbus, see "Busses" case above + if (route->route_group()) { + route->route_group()->set_active (true, this); + } if (!is_track(route) && !is_hidden(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 Hidden: // Show all the tracks we have hidden + if (route->route_group()) { + route->route_group()->set_active (true, this); + } + if (is_hidden(route)) { + // maybe separate groups sorted.push_back (route); remote_ids.insert (route->remote_control_id()); } diff --git a/libs/surfaces/mackie/mackie_control_protocol.h b/libs/surfaces/mackie/mackie_control_protocol.h index f5352731c5..55696f4a3c 100644 --- a/libs/surfaces/mackie/mackie_control_protocol.h +++ b/libs/surfaces/mackie/mackie_control_protocol.h @@ -109,6 +109,7 @@ class MackieControlProtocol Busses, Auxes, Selected, + Hidden, Plugins, }; diff --git a/libs/surfaces/mackie/mcp_buttons.cc b/libs/surfaces/mackie/mcp_buttons.cc index d91cef0168..0d60fe70b6 100644 --- a/libs/surfaces/mackie/mcp_buttons.cc +++ b/libs/surfaces/mackie/mcp_buttons.cc @@ -960,6 +960,7 @@ MackieControlProtocol::outputs_press (Mackie::Button&) Mackie::LedState MackieControlProtocol::outputs_release (Mackie::Button&) { + set_view_mode (Hidden); return none; } Mackie::LedState diff --git a/libs/surfaces/mackie/surface.cc b/libs/surfaces/mackie/surface.cc index 7aa047fcf3..acc997e652 100644 --- a/libs/surfaces/mackie/surface.cc +++ b/libs/surfaces/mackie/surface.cc @@ -1094,10 +1094,15 @@ Surface::update_view_mode_display () id = Button::Aux; text = _("Auxes"); break; + case MackieControlProtocol::Hidden: + show_two_char_display ("HI"); + id = Button::Outputs; + text = _("Hidden Tracks"); + break; case MackieControlProtocol::Selected: show_two_char_display ("SE"); id = Button::User; - text = _("Selected Routes"); + text = _("Selected Tracks"); break; default: break; @@ -1110,6 +1115,7 @@ Surface::update_view_mode_display () view_mode_buttons.push_back (Button::AudioTracks); view_mode_buttons.push_back (Button::MidiTracks); view_mode_buttons.push_back (Button::Aux); + view_mode_buttons.push_back (Button::Outputs); view_mode_buttons.push_back (Button::User); if (id >= 0) { |