aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2011-01-21 04:32:55 +0800
committerRodrigo Moya <rodrigo@gnome-db.org>2011-06-30 00:41:24 +0800
commite5cddb452f481990c84a4758962300dabdbae921 (patch)
treed7919d2ac0ee7615c356ab160dd3423490b88adb /mail
parenta8a426884960e417c6c43094ca50df2288701332 (diff)
downloadgsoc2013-evolution-e5cddb452f481990c84a4758962300dabdbae921.tar
gsoc2013-evolution-e5cddb452f481990c84a4758962300dabdbae921.tar.gz
gsoc2013-evolution-e5cddb452f481990c84a4758962300dabdbae921.tar.bz2
gsoc2013-evolution-e5cddb452f481990c84a4758962300dabdbae921.tar.lz
gsoc2013-evolution-e5cddb452f481990c84a4758962300dabdbae921.tar.xz
gsoc2013-evolution-e5cddb452f481990c84a4758962300dabdbae921.tar.zst
gsoc2013-evolution-e5cddb452f481990c84a4758962300dabdbae921.zip
mail: Use G_DEFINE_TYPE for EmFolderTreeModel
Diffstat (limited to 'mail')
-rw-r--r--mail/em-folder-tree-model.c33
1 files changed, 4 insertions, 29 deletions
diff --git a/mail/em-folder-tree-model.c b/mail/em-folder-tree-model.c
index f29a5fe5d4..c217d63ebb 100644
--- a/mail/em-folder-tree-model.c
+++ b/mail/em-folder-tree-model.c
@@ -97,6 +97,8 @@ extern CamelStore *vfolder_store;
static gpointer parent_class;
static guint signals[LAST_SIGNAL];
+G_DEFINE_TYPE (EMFolderTreeModel, em_folder_tree_model, GTK_TYPE_TREE_STORE)
+
static void
store_info_free (EMFolderTreeModelStoreInfo *si)
{
@@ -378,7 +380,7 @@ folder_tree_model_finalize (GObject *object)
}
static void
-folder_tree_model_class_init (EMFolderTreeModelClass *class)
+em_folder_tree_model_class_init (EMFolderTreeModelClass *class)
{
GObjectClass *object_class;
@@ -501,7 +503,7 @@ folder_tree_model_set_unread_count (EMFolderTreeModel *model,
}
static void
-folder_tree_model_init (EMFolderTreeModel *model)
+em_folder_tree_model_init (EMFolderTreeModel *model)
{
GHashTable *store_index;
GHashTable *uri_index;
@@ -559,33 +561,6 @@ folder_tree_model_init (EMFolderTreeModel *model)
G_CALLBACK (account_added_cb), model);
}
-GType
-em_folder_tree_model_get_type (void)
-{
- static GType type = 0;
-
- if (G_UNLIKELY (type == 0)) {
- static const GTypeInfo type_info = {
- sizeof (EMFolderTreeModelClass),
- (GBaseInitFunc) NULL,
- (GBaseFinalizeFunc) NULL,
- (GClassInitFunc) folder_tree_model_class_init,
- (GClassFinalizeFunc) NULL,
- NULL, /* class_data */
- sizeof (EMFolderTreeModel),
- 0, /* n_preallocs */
- (GInstanceInitFunc) folder_tree_model_init,
- NULL /* value_table */
- };
-
- type = g_type_register_static (
- GTK_TYPE_TREE_STORE, "EMFolderTreeModel",
- &type_info, 0);
- }
-
- return type;
-}
-
EMFolderTreeModel *
em_folder_tree_model_new (void)
{