TnyGtkAttachListModel

TnyGtkAttachListModel — A tree model for mime part instances

Synopsis




#define             TNY_TYPE_GTK_ATTACH_LIST_MODEL_COLUMN
                    TnyGtkAttachListModel;
GType               tny_gtk_attach_list_model_column_get_type
                                                        (void);
GtkTreeModel*       tny_gtk_attach_list_model_new       (void);

Object Hierarchy


  GObject
   +----GtkListStore
         +----TnyGtkAttachListModel

Implemented Interfaces

TnyGtkAttachListModel implements GtkTreeModel, TnyList, GtkTreeDragSource, GtkTreeDragDest and GtkTreeSortable.

Description

A GtkTreeModel for storing TnyMimePart instances.

The implementation inherits the GtkListStore, implements GtkTreeModel and TnyList. If the library was compiled with gnome features, the implementation will handle the mime-type icon automatically.

It's very important to unreference the instance you will get when doing something like this:

TnyMimePart *part;
gtk_tree_model_get (model, &iter, TNY_ATTACH_LIST_MODEL_INSTANCE_COLUMN, &part, -1);
/* use part */
g_object_unref (G_OBJECT(partr));

The column is indeed a G_TYPE_OBJECT column and getting it from the GtkTreeModel will indeed add a reference.

Details

TNY_TYPE_GTK_ATTACH_LIST_MODEL_COLUMN

#define TNY_TYPE_GTK_ATTACH_LIST_MODEL_COLUMN (tny_gtk_attach_list_model_column_get_type())


TnyGtkAttachListModel

typedef struct _TnyGtkAttachListModel TnyGtkAttachListModel;


tny_gtk_attach_list_model_column_get_type ()

GType               tny_gtk_attach_list_model_column_get_type
                                                        (void);

GType system helper function

Returns : a GType

tny_gtk_attach_list_model_new ()

GtkTreeModel*       tny_gtk_attach_list_model_new       (void);

Get a new GtkTreeModel instance suitable for showing TnyMimePart.

Returns : a new GtkTreeModel instance suitable for showing a TnyMimePart

See Also

TnyList, TnyMimePart, GtkTreeModel, GtkListStore, GtkTreeView, TnyGtkAttachListModelColumn