Re: dialog close signal and hiding dialog...



On Tue, 2003-08-12 at 21:12, muppet wrote:
On Tuesday, August 12, 2003, at 08:22  PM, Ross McFarland wrote:

in most cases you should not have any signals connected to your dialog.
that's the beauty and purpose of it. if you're connecting your own
signals then you're probably not using it as it was intended.

that is not true at all.  the GtkDialog is designed for both modal and 
modeless use.  for modal use, the $dialog->run interaction is the 
simplest.  for modeless use, connecting to the response event is the 
only way to do it, because gtk_dialog_run makes the window modal!

if using it in the modeless situation you'd likely need to connect the
other signals as the run function does. for the same reasons that it
does.

i don't see much advantage to using a dialog in modeless situations. all
you get from it then is the response signal to connect to and an
interface for adding buttons that emit responses into it. i would think
that each button would have its own actions when clicked so you'd end up
switching on responses. why not just create each button and attach
individual handlers to them on your own window. other than that you get
the dialog layout which i guess is somewhat useful, but not worth an
entire widget. i'm not saying it's worthless, just saying that what it's
best for, and what he seems to be trying to do with it, is best done
with run.

-rm




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