comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Problem with non-modal children of modal dialogs
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Problem with non-modal children of modal dialogs [message #15792] Mon, 14 June 1999 00:00 Go to previous message
Liam Gumley is currently offline  Liam Gumley
Messages: 473
Registered: November 1994
Senior Member
Phillip & Suzanne David wrote:
> I remember this issue being discussed shortly after IDL 5.0 came out,
> but not noticing that this affected me at the time. However, in some of
> my programs, I display moderately complicated (modal) dialogs, and want
> to provide a help capability for these. The problem I have using IDL is
> that if I display the help in a different window, IDL requires that
> window to be modal as well. Thus, when the user actually desires to use
> the information in the help window, s/he must first close the window
> (remembering the help tip) and act on the help information. There
> appears to be no way to make the window stay up while allowing the user
> to switch back to the modal dialog. My solution so far has been to
> stick with the IDL 4.0 convention to XManager that allows non-modal
> children of modal dialogs (although there appears to be no way to close
> them except by closing the modal dialog). Does anyone know of a better
> way to handle this?

I find it more convenient to manage widget sensitivity manually, using
the SENSITIVE keyword to WIDGET_CONTROL. For example, your program
information structure could contain a master list (array) of widget
names, and corresponding widget ids. Whenever you create a new widget,
you pass the names of the widgets which should be *insensitive* to a
routine that scans through the master list of widget names and ids.
Whenever it finds a match on a widget name, it checks to see if the
widget is active. If it is active, it desensitizes the widget using
WIDGET_CONTROL, ID, SENSITIVE=0
When the widget dies, you then call the same routine with the SENSITIVE
keyword set, and again it scans through the list of widget names.
Whenever it finds a match on a widget name, it checks to see if the
widget is active. If it is active, it sensitizes the widget using
WIDGET_CONTROL, ID, SENSITIVE=1

This way you don't have to worry about MODAL keywords, and you can set
the sensitivity of your widgets exactly to your taste.

Cheers,
Liam.

--
Liam E. Gumley
Space Science and Engineering Center, UW-Madison
http://cimss.ssec.wisc.edu/~gumley
[Message index]
 
Read Message
Read Message
Previous Topic: POLYWARP question.
Next Topic: Looking for CW_ArcBall example code

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 12:20:17 PDT 2025

Total time taken to generate the page: 1.67857 seconds