in reply to Re: Binding Tk events
in thread Binding Tk events
... UPDATE$input->bind('<Return>', [\&mysub, $arg]);
My solution is NOT correct for calling subs with bind...
On the contrary, your solution, forming an anonymous array containing a subroutine ref followed by args to be passed to the sub, is entirely correct. It's the idiom that I normally use for bind calls of this sort.
|
|---|