From: Kero van Gelder Date: 2001-08-07T06:27:03+09:00 Subject: [ruby-talk:19254] Re: Ruby/Tk: how to discard excess messages > An auto-repeat key is sending additional messages while method is > still processing first message. How can I discard the excess > messages? This does not work: def do_it(widget) widget.bind("Any-Key") {} really_do_it() widget.bind("Any-Key") { do_it(widget) } end widget.bind("Any-Key") { do_it(widget) } Because of the single thread queueing the events until after do_it() returns :( Perhaps you could look at the event timestamp? +--- Kero ------------------------------ kero@chello.nl ---+ | Don't split your mentality without thinking twice | | Proud like a God -- Guano Apes | +--- M38c ------- http://members.chello.nl/~k.vangelder ---+