Re: Modal dialogs in Gtk 1.2
- From: Allin Cottrell <cottrell wfu edu>
- To: Jacob Zachariah <jacob_z yahoo com>
- Cc: gtk-devel-list gnome org
- Subject: Re: Modal dialogs in Gtk 1.2
- Date: Wed, 19 Apr 2006 00:20:55 -0400 (EDT)
On Tue, 18 Apr 2006, Jacob Zachariah wrote:
I need to implement modal dialogs in Gtk1.2 as that's
what the target platform supports. I know in Gtk2 i
can do it thru gtk_dialog_run etc.. but i need to do
it in gtk1.2 instead.
I saw on a site, where they say you can use a
secondary gtk_main() for the modal dialog. Is that the
best way or is there another? any good examples?
A secondary gtk_main() does not make a dialog modal, it makes the
dialog blocking, which is a different thing:
modal: the user can't activate any other part of the GUI until the
dialog box is dismissed.
blocking: in the function where the dialog is created, execution
will not continue until the dialog is dismissed (there should be a
gtk_main_quit() attached to that event).
In gtk 1.2 you can use gtk_window_set_modal() to create modality,
if that is what you want.
Many coders consider modal dialogs evil.
--
Allin Cottrell
Department of Economics
Wake Forest University, NC
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]