[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: modal dialogs

cartier@math.uqam.ca (Guillaume Cartier) writes:
 Does anyone know how to do some computations while
 a modal dialog is showing the progress of the computations?
 (like the Finder when it copies files...)

The with-progress-indication is a good start for the model
(I think it is in matts-utils in  the contrib directory).
You probably need two dialogs - the modal dialog to initiate
the process (which exits properly) and a modified version
of with-progress-indication which will allow you to display
a progress bar (similar to the one used with copy for files
by the finder) and to update a text area (e.g the files copied
field) and to print a title.

The problem with modal-dialogs is that they become confused
if you display another dialog or window while they are active.
You could try to wrap the executing code in without-interrupts
and associating the code with a button. For a full example,
see the final eval-enqueue example in chapter 7 (Events) in
the MCL Reference Manual).