Home »
Public Forums »
archive »
Re: Event Handling
Re: Event Handling [message #28152] |
Thu, 22 November 2001 10:43 |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Adam Rankin (arankin@irus.rri.on.ca) writes:
> This one is taking my brain for a spin so ANY help/advice is very, very
> much appreciated.
>
> Right now I'm trying to write a program that will act as a counter that
> displays a ratio of (currentjob/numberofjobs) and it's working. The
> problem comes when I want to add a cancel button.
>
> Right now I use XMANAGER to handle events and that's all I know so don't
> be mad. =) But with if I use XMANAGER to handle the event of the cancel
> button being pressed, it locks up the system and stops running the actual
> calculations that I'm doing.
>
> So in essence I guess I'm looking for a way to handle events in a seperate
> window than the one doing the calculations without locking up the system.
Yes, you are going to have to use Widget_Event to look for
events from this specific button. See the UPDATE method
in my ShowProgress program for an example of how this
is done.
http://www.dfanning.com.programs/showprogress__define.pro
There is an example program. Access it like this:
IDL> .compile showprogress__define
IDL> example
You want the Manual Mode operation.
Cheers,
David
--
David W. Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|
Current Time: Wed Oct 08 10:56:54 PDT 2025
Total time taken to generate the page: 0.00493 seconds