Author Topic: How to activate (focus) the Next/Previous Track  (Read 3428 times)

Offline Ignacio Calvo

  • Newbie
  • *
  • Posts: 4
    • IgnacioCalvo.com
How to activate (focus) the Next/Previous Track
« on: May 16, 2020, 12:07:34 AM »
I want to program two buttons of my MIDI controller to navigate through my tracks. So what I am searching is a way to Activate/Focus the Next/Previous Track. I didn't find a specific Command or Function. So far, I've used Keyboard Down/Up, but the track pane must be focused. I tried Command 'Move Input Focus to Track Pane', but it didn't work. Any ideas?

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1679
Re: How to activate (focus) the Next/Previous Track
« Reply #1 on: May 16, 2020, 05:22:07 PM »
"Strip" "Track" "<Current>" "+1" (for next, "-1" for previous)
"Function" "Select strip"

If you want it works for buses as well, whatever is in focus, it is a bit more complicated (you will need a monitor to retrieve current pane...).

'Move Input Focus...' is to change between buses and tracks (buggy on Cakewalk side, let me know if you need that so I can describe workaround).

Offline Ignacio Calvo

  • Newbie
  • *
  • Posts: 4
    • IgnacioCalvo.com
Re: How to activate (focus) the Next/Previous Track
« Reply #2 on: May 18, 2020, 03:36:27 PM »
Thak you, it works perfectly with only one strange behavior, surely not related with your answer. I will ask for it in Hermu's Novation Impulse preset thread, since this is the preset I am tweaking.

Offline cupax

  • Newbie
  • *
  • Posts: 23
Re: How to activate (focus) the Next/Previous Track
« Reply #3 on: November 24, 2020, 09:35:41 PM »
'Move Input Focus...' is to change between buses and tracks (buggy on Cakewalk side, let me know if you need that so I can describe workaround).

Yes please, I need this workaround. Thanks!

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1679
Re: How to activate (focus) the Next/Previous Track
« Reply #4 on: November 24, 2020, 11:53:04 PM »
Switching between bus and tracks works without bug only in case you "switch" to current strip type first. So, if focus is in tracks, "Switch to tracks" + "Switch to buses" does the trick (and reversed).
For that you need to know currently focused strip type, proper way is monitor "Recall"ed focused strip, remembering changes in Parameter Name monitor.

All that is a bit tricky to explain "step by step". In "X-Touch Mini" preset that is done in "_Strip" control (and corresponding monitor). The button operations are in "_fEBStripSet(_Ch)", the control serve  8 different buttons, relevant part is with  Ch:7 condition.

Note the "Strip" is not System set, you need to define it yourself in the Options tab (as in mentioned preset, the first state is "Track" the second is "Bus").

Offline cupax

  • Newbie
  • *
  • Posts: 23
Re: How to activate (focus) the Next/Previous Track
« Reply #5 on: November 26, 2020, 09:54:07 PM »
Well, this worked and not.

I've managed to make a switch between tracks and busses. It works well until I use my controller only.
If I make a switch between track and busses using my mouse, the controller stays behind - I't wont update the displays and LEDs anymore until I press the programmed "switch strip type" button on it.

So is there a way to get the type of strip of selected track directly from Cakewalk? Or is there a way AZSlow can get info from selected track clicked by mouse, not the controller itself?

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1679
Re: How to activate (focus) the Next/Previous Track
« Reply #6 on: November 27, 2020, 08:54:46 AM »
That is exactly how it works, the type is taken from Cakewalk. Independent how it is set, by mouse or controller.
But preset has to be constructed correctly to react on that correctly.

Offline cupax

  • Newbie
  • *
  • Posts: 23
Re: How to activate (focus) the Next/Previous Track
« Reply #7 on: November 27, 2020, 09:44:28 AM »
Aha, good. But can you just explain me how do you get that information from Cakewalk?
Do I need to use a function, a monitor or something else?

I just want a simple mouse click to define a software state "track_focus" to be "track" od "bus" depending what do you select with the mouse.

Thanks!

Offline Bassman

  • Full Member
  • ***
  • Posts: 158
Re: How to activate (focus) the Next/Previous Track
« Reply #8 on: November 27, 2020, 09:08:15 PM »
Hi :)

Would be interesting to know if the selected track by mouse can be related to a usable variable:)

But I know, WAI can be set at mouse click by making a new Control in the options tab, f.e. _strip, attach it in the hardware tab.
In the action list only set a monitor and in the feedback tab just write WAI to the feedback lis for tbis monitor.

Hope this is correct, I'm not in front of my PC at the moment...
Bassman.

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1679
Re: How to activate (focus) the Next/Previous Track
« Reply #9 on: November 27, 2020, 10:28:50 PM »
I just want a simple mouse click to define a software state "track_focus" to be "track" od "bus" depending what do you select with the mouse.
That is what happens in mentioned "_Strip" control, using "focused" strip monitoring. "Strip" Action is searching some strip, with predefined type.  "Recall focused" Action gets current focused strip and its type from Cakewalk.

Terminology is a bit strange there, but correct. There can be just once "focused" strip, either Track or Bus. But both types have "current" strip all the time, independent which pane is currently in focus. "Current" strip is the last "focused" in the specified type. So if you focus "Track 5" and then "Bus 2": "Track 5" is current Track, "Bus 2" is current Bus, "Bus 2" is focused strip.


I could put that functionality into "Strip", adding "Focused" option into the strip type. But then it needs one more extra parameter, for the focused type. And that Action is already complicated. So I have decided to do this in "Save/Recall", where the strip type can be extracted  from "focused" or previously saved strip.

The monitor is required to persistently save focused type ("Set engine state" in the Logic tab has special meaning, long story... so it is grayed in the "Save/recall" Action in the Logic tab). Since we effectively monitor changes in focused strip, the monitor also update WAI (with X-Touch Mini preset logic, changing focused strip always change WAI there, unlike in many other presets).

The evil is really in details  ;)

Offline cupax

  • Newbie
  • *
  • Posts: 23
Re: How to activate (focus) the Next/Previous Track
« Reply #10 on: November 27, 2020, 11:28:50 PM »
Thank You! The "Save/Recall" action was the key!
But as you've said, the "Focus strip type" function is buggy so I did this workaround:
I mapped the switching strip types inside Cakewalk's options to the PC keyboard shortcuts and then my controller to mimic these keys with the Keyboard action. I know this goes "outside" AZSlow but it just works better.