Destroying widgets?

Hello all!

Sorry if this is a trivial or previously asked question, but there is something I'm not sure I completely understand.

So you have an application with a HPaned (Left for navigating and Right for viewing). Now I assume when a user selects an action from the left, you destroy the previously created widget in the right hpaned and recreate. I've only come to this assumption through lack of "remove" type calls on parent widgets, and trial and error. After all, my aim is to sometimes have a tabbed item in the right or it could be a framed table. So I do so, and get errors like....

Gtk-CRITICAL **: gtk_widget_destroy: assertion `GTK_IS_WIDGET (widget)' failed at ./test line 408.
Gtk-WARNING **: Can't set a parent on widget which has a parent

The HPaned widget right side has first a ScrolledWindow object, so I destroy there and rebuild. I get the desired effect from the application, just with errors.

I'm sure it's just something fundamental missing in my GUI programming skills, but I would greatly appreciate any help getting me on the right track.


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