Re: GTK Modal dialog



Miroslav Rajcic wrote:

I am trying to show the dialog in a modal way.
I've read in some old posts that the way to do it is like this:

...

My problem is that dielog doesn't seem modal at all. When I click on its
parent window, dialog falls back underneath all other windows on the
desktop.
Even setting this doesn't help:
gtk_window_set_modal (GTK_WINDOW (dialog1), TRUE);
gtk_window_set_keep_above(GTK_WINDOW (dialog1), TRUE);

try this:

gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (parent));
gtk_window_set_modal (GTK_WINDOW (dialog), TRUE);

cheers,
Andrei




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