I didn't think a script would work because resume does not appear in the QLab Applescript dictionary. I thought it would be relatively trivial to use the OSC /togglePause method triggered by the MIDI cc you had assigned to both pause and resume all, but can't get that to work reliably on a single cuelist or using a wildcard. I also can't get /pause and /resume OSC methods to work with a classic arm disarm toggle because when the workspace pauses it stops the arm and disarm cues, and also the toggle won't reset itself to the correct state if the pause is cancelled by a different method e.g ESC
As I was typing the above, I realised that the OSC workspace /pause/and /resume methods could be included in a script using shell script and that that script could see if there were currently any paused cues and if there aren't /pause the workspace and if there are /resume. This gets around the lack of a resume in AppleScript.
Because the script is running in a separate process, it continues when the workspace itself is paused, so it seems to work well, although I may have overlooked something.
The solution is a script cue triggered by your MIDI cc message with the following:
tell application id "com.figure53.QLab.5" to tell front workspace
if (count of (cues whose paused is true)) > 0 then
set theOSC to "/resume"
else
set theOSC to "/pause"
end if
do shell script "echo " & quoted form of theOSC & " | nc -u -w 0 127.0.0.1 53535"
end tell
Mic