!7 module SendAIBar > DynPrintLog { S sendTo; bool enabled; start { ownResource(vmBus_onMessage('topInputChanged, voidfunc(fS s) { if (!enabled || !possibleComputerID(sendTo)) ret; q().add(r { dm_privateChat_evalOnOtherMachine(sendTo, "dm_setAIBarText(" + quote(s) + ");") }) })); } visualize { ret centerAndSouthWithMargins(super.visualize(), centerAndEast(withLabel("Send to:", dm_fieldTextField('sendTo)), dm_fieldCheckBox('enabled))); } }