How do you get SoundFlow to hold down keyboard modifiers?
Linked from:
- Christian Scheuer @chrscheuer2018-06-15 19:33:36.818Z
//Start holding down Shift sf.keyboard.modifiers({ isShift: true }); //Release all modifiers sf.keyboard.modifiers();
- SSteve @stevef
Hi. I can't seem to get this to work (on Beta 3.4). Assuming I am using it correctly. In cubase, if you hold shift and then use the down or up arrow on tracks, it adds the next or previous to the selection. So I thought if I scripted
sf.keyboard.modifiers({
isShift: true
sf.keyboard.press({ keys: 'down, down, down, down' });
sf.keyboard.modifiers();It would have the same effect, but it doesn't. This works:
sf.keyboard.press({ keys: 'shift, shift+down, shift+down, shift+down, shift+down' });
But wondered why the other isn't?
Christian Scheuer @chrscheuer2018-07-28 23:22:34.202Z
Correct.
Because the sf.keyboard.press actually resets the modifiers if you don't specify the shift. If we allowed "sticky" stuff before/after, it would break many of our internal commands, and it would more easily lead to subtle bugs.- SSteve @stevef
Ah, get you. This is more for shift clicking?
Christian Scheuer @chrscheuer2018-07-28 23:31:19.099Z
Not sure what you mean by that :)
The sf.keyboard.modifiers I think is probably mostly a legacy action by now. It was originally combined with mouse clicks etc., but those now have dedicated parameters to control their behavior since that is more stable.
I'll look to see if we should completely remove the modifiers action if all it does is introduce confusion.