aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-subscribe-editor.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2009-05-27 23:13:25 +0800
committerMatthew Barnes <mbarnes@redhat.com>2009-05-29 00:13:23 +0800
commitfad4af8a3d4c6f50f7bcceca8d545eb17d6fd056 (patch)
treeae78be371695c3dc18847b87d3f014f985aa3a40 /mail/em-subscribe-editor.c
parent6f5464f34ceec9e5701e3e3e651a40f9e6b3a072 (diff)
downloadgsoc2013-evolution-fad4af8a3d4c6f50f7bcceca8d545eb17d6fd056.tar.gz
gsoc2013-evolution-fad4af8a3d4c6f50f7bcceca8d545eb17d6fd056.tar.zst
gsoc2013-evolution-fad4af8a3d4c6f50f7bcceca8d545eb17d6fd056.zip
Prefer GLib basic types over C types.
Diffstat (limited to 'mail/em-subscribe-editor.c')
-rw-r--r--mail/em-subscribe-editor.c60
1 files changed, 30 insertions, 30 deletions
diff --git a/mail/em-subscribe-editor.c b/mail/em-subscribe-editor.c
index 25c447d62e..df58c808db 100644
--- a/mail/em-subscribe-editor.c
+++ b/mail/em-subscribe-editor.c
@@ -52,7 +52,7 @@ typedef struct _EMSubscribeEditor EMSubscribeEditor;
struct _EMSubscribeEditor {
EDList stores;
- int busy;
+ gint busy;
guint busy_id;
struct _EMSubscribe *current; /* the current one, if any */
@@ -69,14 +69,14 @@ struct _EMSubscribe {
struct _EMSubscribe *next;
struct _EMSubscribe *prev;
- int ref_count;
- int cancel;
- int seq; /* upped every time we refresh */
+ gint ref_count;
+ gint cancel;
+ gint seq; /* upped every time we refresh */
struct _EMSubscribeEditor *editor; /* parent object*/
- char *store_uri;
- int store_id; /* looking up a store */
+ gchar *store_uri;
+ gint store_id; /* looking up a store */
CamelStore *store;
GHashTable *folders;
@@ -88,16 +88,16 @@ struct _EMSubscribe {
GSList *info_list;
/* pending LISTs, EMSubscribeNode's */
- int pending_id;
+ gint pending_id;
EDList pending;
/* queue of pending UN/SUBSCRIBEs, EMsg's */
- int subscribe_id;
+ gint subscribe_id;
EDList subscribe;
/* working variables at runtime */
- int selected_count;
- int selected_subscribed_count;
+ gint selected_count;
+ gint selected_subscribed_count;
guint subscribed_state:1; /* for setting the selection*/
};
@@ -116,8 +116,8 @@ struct _MailMsgListNode {
MailMsg *msg;
};
-static void sub_editor_busy(EMSubscribeEditor *se, int dir);
-static int sub_queue_fill_level(EMSubscribe *sub, EMSubscribeNode *node);
+static void sub_editor_busy(EMSubscribeEditor *se, gint dir);
+static gint sub_queue_fill_level(EMSubscribe *sub, EMSubscribeNode *node);
static void sub_selection_changed(GtkTreeSelection *selection, EMSubscribe *sub);
static void
@@ -169,8 +169,8 @@ struct _zsubscribe_msg {
EMSubscribe *sub;
EMSubscribeNode *node;
- int subscribe;
- char *path;
+ gint subscribe;
+ gchar *path;
};
static void
@@ -246,11 +246,11 @@ static MailMsgInfo sub_subscribe_folder_info = {
/* spath is tree path in string form */
static int
-sub_subscribe_folder (EMSubscribe *sub, EMSubscribeNode *node, int state, const char *spath)
+sub_subscribe_folder (EMSubscribe *sub, EMSubscribeNode *node, gint state, const gchar *spath)
{
struct _zsubscribe_msg *m;
MailMsgListNode *msgListNode;
- int id;
+ gint id;
m = mail_msg_new (&sub_subscribe_folder_info);
m->sub = sub;
@@ -276,7 +276,7 @@ sub_subscribe_folder (EMSubscribe *sub, EMSubscribeNode *node, int state, const
/* ********************************************************************** */
static void
-sub_fill_level(EMSubscribe *sub, CamelFolderInfo *info, GtkTreeIter *parent, int pending)
+sub_fill_level(EMSubscribe *sub, CamelFolderInfo *info, GtkTreeIter *parent, gint pending)
{
CamelFolderInfo *fi;
GtkTreeStore *treestore;
@@ -343,7 +343,7 @@ sub_fill_level(EMSubscribe *sub, CamelFolderInfo *info, GtkTreeIter *parent, in
struct _emse_folderinfo_msg {
MailMsg base;
- int seq;
+ gint seq;
EMSubscribe *sub;
EMSubscribeNode *node;
@@ -353,7 +353,7 @@ struct _emse_folderinfo_msg {
static void
sub_folderinfo_exec (struct _emse_folderinfo_msg *m)
{
- char *pub_full_name=NULL;
+ gchar *pub_full_name=NULL;
if (m->seq == m->sub->seq) {
camel_operation_register(m->base.cancel);
@@ -424,7 +424,7 @@ static int
sub_queue_fill_level(EMSubscribe *sub, EMSubscribeNode *node)
{
struct _emse_folderinfo_msg *m;
- int id;
+ gint id;
d(printf("%s:%s: Starting get folderinfo of '%s'\n", G_STRLOC, G_STRFUNC,
node?node->info->full_name:"<root>"));
@@ -450,7 +450,7 @@ sub_queue_fill_level(EMSubscribe *sub, EMSubscribeNode *node)
/* (un) subscribes the current selection */
static void
-sub_subscribe_toggled(GtkCellRendererToggle *render, const char *spath, EMSubscribe *sub)
+sub_subscribe_toggled(GtkCellRendererToggle *render, const gchar *spath, EMSubscribe *sub)
{
GtkTreeIter iter;
GtkTreeModel *model = gtk_tree_view_get_model(sub->tree);
@@ -468,7 +468,7 @@ sub_subscribe_toggled(GtkCellRendererToggle *render, const char *spath, EMSubscr
}
}
-static void sub_do_changed(GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *iter, void *data)
+static void sub_do_changed(GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *iter, gpointer data)
{
EMSubscribe *sub = data;
EMSubscribeNode *node;
@@ -484,7 +484,7 @@ static void sub_do_changed(GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *
static void
sub_selection_changed(GtkTreeSelection *selection, EMSubscribe *sub)
{
- int dosub = TRUE, dounsub = TRUE;
+ gint dosub = TRUE, dounsub = TRUE;
sub->selected_count = 0;
sub->selected_subscribed_count = 0;
@@ -516,7 +516,7 @@ sub_row_expanded(GtkTreeView *tree, GtkTreeIter *iter, GtkTreePath *path, EMSubs
EMSubscribeNode *node;
GtkTreeIter child;
GtkTreeModel *model = (GtkTreeModel *)gtk_tree_view_get_model(tree);
- char *row_name;
+ gchar *row_name;
gtk_tree_model_get(model, iter, 1, &row_name, -1);
d(printf("%s:%s: row-expanded '%s'\n", G_STRLOC, G_STRFUNC,
@@ -582,7 +582,7 @@ sub_destroy(GtkWidget *w, EMSubscribe *sub)
}
static EMSubscribe *
-subscribe_new(EMSubscribeEditor *se, const char *uri)
+subscribe_new(EMSubscribeEditor *se, const gchar *uri)
{
EMSubscribe *sub;
@@ -720,7 +720,7 @@ sub_editor_refresh(GtkWidget *w, EMSubscribeEditor *se)
}
static void
-sub_editor_got_store(char *uri, CamelStore *store, void *data)
+sub_editor_got_store(gchar *uri, CamelStore *store, gpointer data)
{
struct _EMSubscribe *sub = data;
@@ -732,7 +732,7 @@ sub_editor_got_store(char *uri, CamelStore *store, void *data)
static void
sub_editor_combobox_changed (GtkWidget *w, EMSubscribeEditor *se)
{
- int i, n;
+ gint i, n;
struct _EMSubscribe *sub;
d(printf("combobox changed\n"));
@@ -784,9 +784,9 @@ static gboolean sub_editor_timeout(EMSubscribeEditor *se)
return TRUE;
}
-static void sub_editor_busy(EMSubscribeEditor *se, int dir)
+static void sub_editor_busy(EMSubscribeEditor *se, gint dir)
{
- int was;
+ gint was;
was = se->busy != 0;
se->busy += dir;
@@ -831,7 +831,7 @@ GtkDialog *em_subscribe_editor_new(void)
GtkCellRenderer *cell;
GtkListStore *store;
GtkTreeIter gtiter;
- char *gladefile;
+ gchar *gladefile;
se = g_malloc0(sizeof(*se));
e_dlist_init(&se->stores);