Re: construct functions
- From: murrayc t-online de (Murray Cumming)
- To: Havoc Pennington <hp redhat com>
- Cc: gtk-devel-list <gtk-devel-list gnome org>
- Subject: Re: construct functions
- Date: 23 Oct 2001 16:21:40 +0200
On Tue, 2001-10-23 at 15:01, Havoc Pennington wrote:
>
> murrayc t-online de (Murray Cumming) writes:
> > A lot of objects seem to be missing construct functions for language
> > bindings. Do I have permission to add these as I discover the need? It
> > should be a simple matter of moving code from the _new function to
> > _construct functions, then calling those _construct functions from the
> > _new functions.
>
> Instead of construct functions, objects are supposed to have
> construct-time object properties. If anything requires a construct
> function it is broken, file a bug report about it.
So we set these properties immediately after using g_type_new()? If
there is an existing example of this, can you help me out by pointing me
to it?
So, is gtk_tree_view_new_with_model() broken? :
GtkWidget *
gtk_tree_view_new_with_model (GtkTreeModel *model)
{
GtkTreeView *tree_view;
tree_view = GTK_TREE_VIEW (gtk_type_new (gtk_tree_view_get_type ()));
gtk_tree_view_set_model (tree_view, model);
return GTK_WIDGET (tree_view);
}
Maybe this is why we have gtk_tree_view_set_model().
--
Murray Cumming
murrayc usa net
www.murrayc.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]