Path: utzoo!attcan!uunet!husc6!mit-eddie!fenchurch.mit.edu!jbs From: jbs@fenchurch.MIT.EDU (Jeff Siegal) Newsgroups: comp.windows.x Subject: Re: question regarding toolkit callback functions Message-ID: <9711@eddie.MIT.EDU> Date: 18 Jul 88 23:06:32 GMT References: <8807172352.AA17403@special-k.ai.mit.edu> Sender: uucp@eddie.MIT.EDU Reply-To: jbs@fenchurch.MIT.EDU (Jeff Siegal) Organization: MIT EE/CS Computer Facilities, Cambridge, MA Lines: 27 In article <8807172352.AA17403@special-k.ai.mit.edu> sundar@WHEATIES.AI.MIT.EDU (Sundar Narasimhan) writes: >[...] >I have an application that has a rather complicated function bound to >a command button's callback. Since this function takes a long time, >ideally I would like to be able to provide feedback to the user at >intermediate points [...] Rather than execute the complicated function directly from the callback, you could queue events to display the status messages and do the processing: queue_event(display_message1) queue_event(processing_part_1) queue_event(display_message2) queue_event(processing_part_2) . . . After queueing all the events, the command button callback would return, and the events would be processed. I don't see anything directly intended to be used as queue_event() above, but perhaps you could use the timeout mechanism (maybe with a zero or small time interval). Jeff Siegal