Re: Overriding iface implementations



On Wed, 2004-02-25 at 09:03, Owen Taylor wrote:

> > Namely, the file chooser uses a GtkListStore for the shortcuts list.  I
> > want to make just the bookmarks part reorderable, so I need to override
> > ::row_draggable on the source side, and ::row_drop_possible on the
> > destination side.
> You just add the interface again and set the functions you want
> and don't set the others. g_type_interface_peek_parent() can
> be used to chain up.

That means deriving from GtkListStore and re-adding the interfaces,
right?

My question is more along the following lines.  Can I override interface
methods for a particular instance of a class?  E.g.

	GtkTreeDragSourceIface my_methods = {
	  my_row_draggable_func,
	  NULL,
	  NULL
	};

	list = gtk_list_store_new ();
	override_interface (list, GTK_TYPE_TREE_DRAG_SOURCE, my_methods);

  Federico





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