ScrolledWindow in GTK--



Hi.

 Can I remove an object from a ScrolledWindow? Every time I try, I get
the following message:

** WARNING **: file gtkcontainer.c: line 359 (gtk_container_remove):
"widget->parent == GTK_WIDGET (container)"

 This is the relevant part of the source:

----

  if ( ptTree )
  {
    ptScrolledWnd->remove (ptTree);
    delete ptTree;
  }
  
  ptTree = new TRTSceneTree (ptScene);
  assert ( ptTree );
  ptTree->show();

  ptScrolledWnd->add (ptTree);

----

 I destroy the previous tree (TRTSceneTree inherits from Gtk_Tree), and
create a new one. It was working when I was adding/removing the tree
directly to/from the VBox.

 (I'm using GTK+ 1.0.1 and GTK-- 0.9.3).

 Angel.



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