Re: Blockingsignals for all widgets(except one or two)

You can safely ignoe my last post.
I have worked  out a way to do it.

If anyone is ineterested this is what I came up with.

GtkWidget *MainW=gtk_window_new(GTK_WINDOW_TOPLEVEL);


//add many widgets to MainW


void do_sens(GtkWidget *w,gpointer data)

void sens_all(gboolean sens)
        gtk_container_foreach           (GTK_CONTAINER(MainW),
                                        (gpointer *)sens);

It seems to do what I wanted.


On Thu, 2 Nov 2000, Jason Tan wrote:

Hi All,

I have an applciaiton with many many user contorls(widgets) and under
certain cirecumstances I want to be able to block all the signals from all
widgets excpet one or two.

Is there an easy-ish way to do this?

The gui stores info about bales of wool in several places and under
certain circumstances we don't want any processing to be able to
continue until the user has verified the details being displayed are

I could put in a variable that can be set when I am in the mode where I
want the user to verify before continuing, then test that variable in
every callback, but I have a lot of callbacks and this would be a lot of

Does anyone have a better suggestion or know a way to do this.

I guess what I really want to do is soemthign like


The bit I can't work out is how to do the block all.

Any suggestions very gratefully received.

I am using glade, so there might be some celever way to gt all the child
widgets fromt eh top level window using sem of the support functions, but
I haven't worked out how to do that yet either.

jason tan

gtk-app-devel-list mailing list
gtk-app-devel-list gnome org

Jason Tan                                                jason rebel net au
         Some people have a way about them that seems to say: "If I have
              only one life to live, let me live it as a jerk."

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