Hi Daniel,
In the list of example macros supplied with Logelloop, you’ll find a macro called “Push to record”.
This macro does what you ask and is actually based on “WaitUserAction”, but with the argument “Relese”.
The text of the macro is this :
//************************************** begin *************************
// Will set the main looper to record
Record
// wait the midi, mouse or key to be released
WaitUserAction Release
// Stop recording
Record
//*************************************** end **************************
Best,
Philippe