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

gtk_container_remove




Hi,

I'm trying to create a UI whereby you can choose (from a combo box) an
option, and each time you choose a different option, a new set of UI
widgets is shown (replacing what was shown before). (such as in the
GNOME control center).

I though that to do this all I would have to do is do something like:

gtk_container_remove( my_container, widget);

and remove the old vbox widget I had stored there, and replaced it by:

gtk_container_add( my_container, newwidget);

Ok, so this works, I can change what widget is shown, except when I try
to change the widget shown back to one I've already had. I get an
assertion failure because my widget has suddenly become not a widget. I
think it is because gtk_container_remove is deleting the widget when it
is removed?

any ideas as to why I can't change back to a widget I have had before?

Also, is this the best way to go about it? I couldn't see anything more
elegant

cheers
-- 

Jamie Love
  jlove@clear.net.nz
  jdl28@student.canterbury.ac.nz



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