diff options
Diffstat (limited to 'plugins')
107 files changed, 1481 insertions, 1481 deletions
diff --git a/plugins/addressbook-file/addressbook-file.c b/plugins/addressbook-file/addressbook-file.c index 3bccf0a229..d651ad4a56 100644 --- a/plugins/addressbook-file/addressbook-file.c +++ b/plugins/addressbook-file/addressbook-file.c @@ -32,8 +32,8 @@ e_book_file_dummy (EPlugin *epl, EConfigHookItemFactoryData *data) { EABConfigTargetSource *t = (EABConfigTargetSource *) data->target; ESource *source = t->source; - char *uri_text; - const char *relative_uri; + gchar *uri_text; + const gchar *relative_uri; uri_text = e_source_get_uri (source); if (strncmp (uri_text, "file", 4)) { diff --git a/plugins/attachment-reminder/attachment-reminder.c b/plugins/attachment-reminder/attachment-reminder.c index ccf14beb30..e0b85f5b89 100644 --- a/plugins/attachment-reminder/attachment-reminder.c +++ b/plugins/attachment-reminder/attachment-reminder.c @@ -68,7 +68,7 @@ enum { CLUE_N_COLUMNS }; -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); GtkWidget *e_plugin_lib_get_configure_widget (EPlugin *epl); void org_gnome_evolution_attachment_reminder (EPlugin *ep, EMEventTargetComposer *t); @@ -77,7 +77,7 @@ GtkWidget* org_gnome_attachment_reminder_config_option (struct _EPlugin *epl, st static gboolean ask_for_missing_attachment (EPlugin *ep, GtkWindow *widget); static gboolean check_for_attachment_clues (gchar *msg); static gboolean check_for_attachment (EMsgComposer *composer); -static gchar* strip_text_msg (gchar *msg); +static gchar * strip_text_msg (gchar *msg); static void commit_changes (UIData *ui); static void cell_edited_callback (GtkCellRendererText *cell, gchar *path_string, @@ -85,8 +85,8 @@ static void cell_edited_callback (GtkCellRendererText *cell, gchar *path_string static gboolean clue_foreach_check_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *iter, UIData *ui); -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { return 0; } @@ -193,7 +193,7 @@ check_for_attachment (EMsgComposer *composer) return (e_attachment_store_get_num_attachments (store) > 0); } -static gchar* +static gchar * strip_text_msg (gchar *msg) { gchar **lines = g_strsplit ( msg, "\n", -1); @@ -233,7 +233,7 @@ commit_changes (UIData *ui) valid = gtk_tree_model_get_iter_first (model, &iter); while (valid) { - char *keyword; + gchar *keyword; gtk_tree_model_get (model, &iter, CLUE_KEYWORD_COLUMN, &keyword, -1); /* Check if the keyword is not empty */ @@ -252,7 +252,7 @@ static void clue_check_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *iter, UIData *ui) { GtkTreeSelection *selection; - char *keyword = NULL; + gchar *keyword = NULL; gboolean valid; selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (ui->treeview)); @@ -285,7 +285,7 @@ clue_foreach_check_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIter valid = gtk_tree_model_get_iter_first (model, iter); while (valid && gtk_list_store_iter_is_valid (ui->store, iter)) { - char *keyword = NULL; + gchar *keyword = NULL; gtk_tree_model_get (model, iter, CLUE_KEYWORD_COLUMN, &keyword, -1); /* Check if the keyword is not empty and then emit the row-changed signal (if we delete the row, then the iter gets corrupted) */ @@ -458,7 +458,7 @@ e_plugin_lib_get_configure_widget (EPlugin *epl) UIData *ui = g_new0 (UIData, 1); - char *gladefile; + gchar *gladefile; gladefile = g_build_filename (EVOLUTION_PLUGINDIR, "attachment-reminder.glade", diff --git a/plugins/audio-inline/audio-inline.c b/plugins/audio-inline/audio-inline.c index c4c3c098ae..41744fc641 100644 --- a/plugins/audio-inline/audio-inline.c +++ b/plugins/audio-inline/audio-inline.c @@ -38,15 +38,15 @@ #define d(x) -void org_gnome_audio_inline_format (void *ep, EMFormatHookTarget *t); +void org_gnome_audio_inline_format (gpointer ep, EMFormatHookTarget *t); -static volatile int org_gnome_audio_class_id_counter = 0; +static volatile gint org_gnome_audio_class_id_counter = 0; struct _org_gnome_audio_inline_pobject { EMFormatHTMLPObject object; CamelMimePart *part; - char *filename; + gchar *filename; GstElement *playbin; gulong bus_id; GstState target_state; @@ -197,7 +197,7 @@ org_gnome_audio_inline_play_clicked (GtkWidget *button, EMFormatHTMLPObject *pob CamelStream *stream; CamelDataWrapper *data; GError *error = NULL; - int argc = 1; + gint argc = 1; const gchar *argv [] = { "org_gnome_audio_inline", NULL }; /* FIXME this is ugly, we should stream this directly to gstreamer */ @@ -213,8 +213,8 @@ org_gnome_audio_inline_play_clicked (GtkWidget *button, EMFormatHTMLPObject *pob d(printf ("audio inline formatter: init gst playbin\n")); - if (gst_init_check (&argc, (char ***) &argv, &error)) { - char *uri; + if (gst_init_check (&argc, (gchar ***) &argv, &error)) { + gchar *uri; GstBus *bus; /* create a disk reader */ @@ -254,7 +254,7 @@ org_gnome_audio_inline_play_clicked (GtkWidget *button, EMFormatHTMLPObject *pob } static GtkWidget * -org_gnome_audio_inline_add_button (GtkWidget *box, const char *stock_icon, GCallback cb, gpointer data, gboolean sensitive) +org_gnome_audio_inline_add_button (GtkWidget *box, const gchar *stock_icon, GCallback cb, gpointer data, gboolean sensitive) { GtkWidget *button; @@ -288,10 +288,10 @@ org_gnome_audio_inline_button_panel (EMFormatHTML *efh, GtkHTMLEmbedded *eb, EMF } void -org_gnome_audio_inline_format (void *ep, EMFormatHookTarget *t) +org_gnome_audio_inline_format (gpointer ep, EMFormatHookTarget *t) { struct _org_gnome_audio_inline_pobject *pobj; - char *classid = g_strdup_printf ("org-gnome-audio-inline-button-panel-%d", org_gnome_audio_class_id_counter); + gchar *classid = g_strdup_printf ("org-gnome-audio-inline-button-panel-%d", org_gnome_audio_class_id_counter); org_gnome_audio_class_id_counter ++; diff --git a/plugins/backup-restore/backup-restore.c b/plugins/backup-restore/backup-restore.c index 59c04a605b..92d36e71d8 100644 --- a/plugins/backup-restore/backup-restore.c +++ b/plugins/backup-restore/backup-restore.c @@ -52,7 +52,7 @@ typedef enum _br_flags { }br_flags; static void -backup (const char *filename, gboolean restart) +backup (const gchar *filename, gboolean restart) { if (restart) execl (EVOLUTION_TOOLSDIR "/evolution-backup", "evolution-backup", "--gui", "--backup", "--restart", filename, NULL); @@ -61,7 +61,7 @@ backup (const char *filename, gboolean restart) } static void -restore (const char *filename, gboolean restart) +restore (const gchar *filename, gboolean restart) { if (restart) execl (EVOLUTION_TOOLSDIR "/evolution-backup", "evolution-backup", "--gui", "--restore", "--restart", filename, NULL); @@ -70,10 +70,10 @@ restore (const char *filename, gboolean restart) } static gboolean -sanity_check (const char *filename) +sanity_check (const gchar *filename) { - char *command; - int result; + gchar *command; + gint result; command = g_strdup_printf ("%s/evolution-backup --check %s", EVOLUTION_TOOLSDIR, filename); result = system (command); @@ -89,11 +89,11 @@ sanity_check (const char *filename) } static guint32 -dialog_prompt_user(GtkWindow *parent, const char *string, const char *tag, const char *arg0, ...) +dialog_prompt_user(GtkWindow *parent, const gchar *string, const gchar *tag, const gchar *arg0, ...) { GtkWidget *mbox, *check = NULL; va_list ap; - int button; + gint button; guint32 mask = 0; va_start(ap, arg0); @@ -120,7 +120,7 @@ dialog_prompt_user(GtkWindow *parent, const char *string, const char *tag, const } static gboolean -epbr_perform_pre_backup_checks (char* dir) +epbr_perform_pre_backup_checks (gchar * dir) { #ifdef G_OS_WIN32 return TRUE; @@ -134,7 +134,7 @@ org_gnome_backup_restore_backup (EPlugin *ep, ESMenuTargetShell *target) { GtkWidget *dlg; GtkWidget *vbox; - int response; + gint response; dlg = e_file_get_save_filesel(target->target.widget, _("Select name of the Evolution backup file"), NULL, GTK_FILE_CHOOSER_ACTION_SAVE); @@ -150,10 +150,10 @@ org_gnome_backup_restore_backup (EPlugin *ep, ESMenuTargetShell *target) response = gtk_dialog_run (GTK_DIALOG (dlg)); if (response == GTK_RESPONSE_OK) { - char *filename; + gchar *filename; guint32 mask; - char *uri = NULL; - char *dir; + gchar *uri = NULL; + gchar *dir; uri = gtk_file_chooser_get_current_folder_uri(GTK_FILE_CHOOSER (dlg)); e_file_update_save_path(uri, TRUE); @@ -186,7 +186,7 @@ org_gnome_backup_restore_restore (EPlugin *ep, ESMenuTargetShell *target) { GtkWidget *dlg; GtkWidget *vbox; - int response; + gint response; dlg = e_file_get_save_filesel(target->target.widget, _("Select name of the Evolution backup file to restore"), NULL, GTK_FILE_CHOOSER_ACTION_OPEN); @@ -200,8 +200,8 @@ org_gnome_backup_restore_restore (EPlugin *ep, ESMenuTargetShell *target) response = gtk_dialog_run (GTK_DIALOG (dlg)); if (response == GTK_RESPONSE_OK) { - char *filename; - char *uri = NULL; + gchar *filename; + gchar *uri = NULL; uri = gtk_file_chooser_get_current_folder_uri(GTK_FILE_CHOOSER (dlg)); e_file_update_save_path(uri, TRUE); @@ -232,7 +232,7 @@ check_toggled (GtkToggleButton *button, GnomeDruid *druid) { GtkWidget *box = g_object_get_data ((GObject *)button, "box"); gboolean state = gtk_toggle_button_get_active ((GtkToggleButton *)button); - char *prevfile = g_object_get_data ((GObject *)druid, "restore-file"); + gchar *prevfile = g_object_get_data ((GObject *)druid, "restore-file"); gtk_widget_set_sensitive (box, state); gnome_druid_set_show_finish (druid, state); @@ -249,7 +249,7 @@ static void restore_wizard (GnomeDruidPage *druidpage, GnomeDruid *druid, gpointer user_data) { gboolean state = GPOINTER_TO_INT(g_object_get_data((GObject *)druid, "restore")) ? TRUE:FALSE; - char *file = g_object_get_data ((GObject *)druid, "restore-file"); + gchar *file = g_object_get_data ((GObject *)druid, "restore-file"); if (state) { if (!file ||!sanity_check (file)) { @@ -263,8 +263,8 @@ restore_wizard (GnomeDruidPage *druidpage, GnomeDruid *druid, gpointer user_data static void file_changed (GtkFileChooser *chooser, GnomeDruid *druid) { - char *file = NULL, *prevfile=NULL; - char *uri = NULL; + gchar *file = NULL, *prevfile=NULL; + gchar *uri = NULL; uri = gtk_file_chooser_get_current_folder_uri(GTK_FILE_CHOOSER (chooser)); e_file_update_save_path(uri, TRUE); diff --git a/plugins/backup-restore/backup.c b/plugins/backup-restore/backup.c index 19e9e98bb1..67dea3e6a3 100644 --- a/plugins/backup-restore/backup.c +++ b/plugins/backup-restore/backup.c @@ -43,18 +43,18 @@ #define ARCHIVE_NAME "evolution-backup.tar.gz" static gboolean backup_op = FALSE; -static char *bk_file = NULL; +static gchar *bk_file = NULL; static gboolean restore_op = FALSE; -static char *res_file = NULL; +static gchar *res_file = NULL; static gboolean check_op = FALSE; -static char *chk_file = NULL; +static gchar *chk_file = NULL; static gboolean restart_arg = FALSE; static gboolean gui_arg = FALSE; static gchar **opt_remaining = NULL; -static int result=0; +static gint result=0; static GtkWidget *progress_dialog; static GtkWidget *pbar; -static char *txt = NULL; +static gchar *txt = NULL; gboolean complete = FALSE; static GOptionEntry options[] = { @@ -80,11 +80,11 @@ static GOptionEntry options[] = { #define CANCEL(x) if (x) return; static GString * -replace_string (const char *text, const char *find, const char *replace) +replace_string (const gchar *text, const gchar *find, const gchar *replace) { - const char *p, *next; + const gchar *p, *next; GString *str; - int find_len; + gint find_len; g_return_val_if_fail (text != NULL, NULL); g_return_val_if_fail (find != NULL, NULL); @@ -110,9 +110,9 @@ replace_string (const char *text, const char *find, const char *replace) } static void -replace_in_file (const char *filename, const char *find, const char *replace) +replace_in_file (const gchar *filename, const gchar *find, const gchar *replace) { - char *content = NULL; + gchar *content = NULL; GError *error = NULL; GString *filenamestr = NULL; @@ -157,7 +157,7 @@ replace_in_file (const char *filename, const char *find, const char *replace) } static void -run_cmd (const char *cmd) +run_cmd (const gchar *cmd) { if (!cmd) return; @@ -175,10 +175,10 @@ run_cmd (const char *cmd) } static void -backup (const char *filename) +backup (const gchar *filename) { - char *command; - char *quotedfname; + gchar *command; + gchar *quotedfname; g_return_if_fail (filename && *filename); quotedfname = g_shell_quote(filename); @@ -222,10 +222,10 @@ backup (const char *filename) } static void -restore (const char *filename) +restore (const gchar *filename) { - char *command; - char *quotedfname; + gchar *command; + gchar *quotedfname; g_return_if_fail (filename && *filename); quotedfname = g_shell_quote(filename); @@ -274,10 +274,10 @@ restore (const char *filename) } static void -check (const char *filename) +check (const gchar *filename) { - char *command; - char *quotedfname; + gchar *command; + gchar *quotedfname; g_return_if_fail (filename && *filename); quotedfname = g_shell_quote(filename); @@ -359,10 +359,10 @@ dlg_response (GtkWidget *dlg, gint response, gpointer data) gtk_main_quit (); } -int -main (int argc, char **argv) +gint +main (gint argc, gchar **argv) { - char *file = NULL, *oper = NULL; + gchar *file = NULL, *oper = NULL; gint i; GError *error = NULL; @@ -384,17 +384,17 @@ main (int argc, char **argv) for (i = 0; i < g_strv_length (opt_remaining); i++) { if (backup_op) { oper = _("Backing up to the folder %s"); - d(g_message ("Backing up to the folder %s", (char *) opt_remaining[i])); - bk_file = g_strdup ((char *) opt_remaining[i]); + d(g_message ("Backing up to the folder %s", (gchar *) opt_remaining[i])); + bk_file = g_strdup ((gchar *) opt_remaining[i]); file = bk_file; } else if (restore_op) { oper = _("Restoring from the folder %s"); - d(g_message ("Restoring from the folder %s", (char *) opt_remaining[i])); - res_file = g_strdup ((char *) opt_remaining[i]); + d(g_message ("Restoring from the folder %s", (gchar *) opt_remaining[i])); + res_file = g_strdup ((gchar *) opt_remaining[i]); file = res_file; } else if (check_op) { - d(g_message ("Checking %s", (char *) opt_remaining[i])); - chk_file = g_strdup ((char *) opt_remaining[i]); + d(g_message ("Checking %s", (gchar *) opt_remaining[i])); + chk_file = g_strdup ((gchar *) opt_remaining[i]); } } } diff --git a/plugins/bbdb/bbdb.c b/plugins/bbdb/bbdb.c index 2f375ac43b..8cd8535a73 100644 --- a/plugins/bbdb/bbdb.c +++ b/plugins/bbdb/bbdb.c @@ -42,7 +42,7 @@ #define d(x) /* Plugin hooks */ -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); void bbdb_handle_send (EPlugin *ep, EMEventTargetComposer *target); GtkWidget *bbdb_page_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data); @@ -59,11 +59,11 @@ struct bbdb_stuff { /* Static forward declarations */ static gboolean bbdb_timeout (gpointer data); -static void bbdb_do_it (EBook *book, const char *name, const char *email); -static void add_email_to_contact (EContact *contact, const char *email); +static void bbdb_do_it (EBook *book, const gchar *name, const gchar *email); +static void add_email_to_contact (EContact *contact, const gchar *email); static void enable_toggled_cb (GtkWidget *widget, gpointer data); static void source_changed_cb (ESourceComboBox *source_combo_box, struct bbdb_stuff *stuff); -static GtkWidget *create_addressbook_option_menu (struct bbdb_stuff *stuff, int type); +static GtkWidget *create_addressbook_option_menu (struct bbdb_stuff *stuff, gint type); static void cleanup_cb (GObject *o, gpointer data); static ESource * @@ -105,8 +105,8 @@ find_esource_by_uri (ESourceList *source_list, const gchar *target_uri) return NULL; } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { /* Start up the plugin. */ if (enable) { @@ -134,8 +134,8 @@ bbdb_timeout (gpointer data) typedef struct { - char *name; - char *email; + gchar *name; + gchar *email; } todo_struct; static void @@ -192,7 +192,7 @@ bbdb_do_in_thread (gpointer data) } static void -bbdb_do_thread (const char *name, const char *email) +bbdb_do_thread (const gchar *name, const gchar *email) { todo_struct *td; @@ -271,9 +271,9 @@ bbdb_handle_send (EPlugin *ep, EMEventTargetComposer *target) } static void -bbdb_do_it (EBook *book, const char *name, const char *email) +bbdb_do_it (EBook *book, const gchar *name, const gchar *email) { - char *query_string, *delim, *temp_name = NULL; + gchar *query_string, *delim, *temp_name = NULL; EBookQuery *query; GList *contacts, *l; EContact *contact; @@ -375,10 +375,10 @@ bbdb_do_it (EBook *book, const char *name, const char *email) } EBook * -bbdb_open_addressbook (int type) +bbdb_open_addressbook (gint type) { GConfClient *gconf; - char *uri; + gchar *uri; EBook *book = NULL; gboolean status; @@ -439,7 +439,7 @@ bbdb_check_gaim_enabled (void) } static void -add_email_to_contact (EContact *contact, const char *email) +add_email_to_contact (EContact *contact, const gchar *email) { GList *emails; @@ -497,7 +497,7 @@ enable_gaim_toggled_cb (GtkWidget *widget, gpointer data) struct bbdb_stuff *stuff = (struct bbdb_stuff *) data; gboolean active; ESource *selected_source; - char *addressbook_gaim; + gchar *addressbook_gaim; active = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)); @@ -562,12 +562,12 @@ gaim_source_changed_cb (ESourceComboBox *source_combo_box, } static GtkWidget * -create_addressbook_option_menu (struct bbdb_stuff *stuff, int type) +create_addressbook_option_menu (struct bbdb_stuff *stuff, gint type) { GtkWidget *combo_box; ESourceList *source_list; ESource *selected_source; - char *selected_source_uri; + gchar *selected_source_uri; GConfClient *gconf = stuff->target->gconf; diff --git a/plugins/bbdb/bbdb.h b/plugins/bbdb/bbdb.h index 62887a8ed0..994aab0385 100644 --- a/plugins/bbdb/bbdb.h +++ b/plugins/bbdb/bbdb.h @@ -36,7 +36,7 @@ #define BBDB_BLIST_CHECK_INTERVAL (2 * 60) /* bbdb.c */ -EBook *bbdb_open_addressbook (int type); +EBook *bbdb_open_addressbook (gint type); gboolean bbdb_check_gaim_enabled (void); /* gaimbuddies.c */ diff --git a/plugins/bbdb/gaimbuddies.c b/plugins/bbdb/gaimbuddies.c index d23749de66..f50498fc48 100644 --- a/plugins/bbdb/gaimbuddies.c +++ b/plugins/bbdb/gaimbuddies.c @@ -50,20 +50,20 @@ #include "bbdb.h" typedef struct { - char *account_name; - char *proto; - char *alias; - char *icon; + gchar *account_name; + gchar *proto; + gchar *alias; + gchar *icon; } GaimBuddy; /* Forward declarations for this file. */ static gboolean bbdb_merge_buddy_to_contact (EBook *book, GaimBuddy *b, EContact *c); static GList *bbdb_get_gaim_buddy_list (void); -static char *get_node_text (xmlNodePtr node); -static char *get_buddy_icon_from_setting (xmlNodePtr setting); +static gchar *get_node_text (xmlNodePtr node); +static gchar *get_buddy_icon_from_setting (xmlNodePtr setting); static void free_buddy_list (GList *blist); static void parse_buddy_group (xmlNodePtr group, GList **buddies, GSList *blocked); -static EContactField proto_to_contact_field (const char *proto); +static EContactField proto_to_contact_field (const gchar *proto); void bbdb_sync_buddy_list_check (void) @@ -71,8 +71,8 @@ bbdb_sync_buddy_list_check (void) GConfClient *gconf; struct stat statbuf; time_t last_sync; - char *blist_path; - char *last_sync_str; + gchar *blist_path; + gchar *last_sync_str; gconf = gconf_client_get_default (); @@ -87,7 +87,7 @@ bbdb_sync_buddy_list_check (void) /* Reprocess the buddy list if it's been updated. */ last_sync_str = gconf_client_get_string (gconf, GCONF_KEY_GAIM_LAST_SYNC, NULL); - if (last_sync_str == NULL || ! strcmp ((const char *)last_sync_str, "")) + if (last_sync_str == NULL || ! strcmp ((const gchar *)last_sync_str, "")) last_sync = (time_t) 0; else last_sync = (time_t) g_ascii_strtoull (last_sync_str, NULL, 10); @@ -179,7 +179,7 @@ bbdb_sync_buddy_list (void) { GConfClient *gconf; time_t last_sync; - char *last_sync_str; + gchar *last_sync_str; gconf = gconf_client_get_default (); @@ -199,7 +199,7 @@ im_list_contains_buddy (GList *ims, GaimBuddy *b) GList *l; for (l = ims; l != NULL; l = l->next) { - char *im = (char *) l->data; + gchar *im = (gchar *) l->data; if (! strcmp (im, b->account_name)) return TRUE; @@ -241,12 +241,12 @@ bbdb_merge_buddy_to_contact (EBook *book, GaimBuddy *b, EContact *c) g_warning ("bbdb: Could not read buddy icon: %s\n", error->message); g_error_free (error); for (l = ims; l != NULL; l = l->next) - g_free ((char *) l->data); + g_free ((gchar *) l->data); g_list_free (ims); return dirty; } - photo->data.inlined.data = (unsigned char *)contents; + photo->data.inlined.data = (guchar *)contents; e_contact_set (c, E_CONTACT_PHOTO, (gpointer) photo); dirty = TRUE; } @@ -257,14 +257,14 @@ bbdb_merge_buddy_to_contact (EBook *book, GaimBuddy *b, EContact *c) e_contact_photo_free (photo); for (l = ims; l != NULL; l = l->next) - g_free ((char *) l->data); + g_free ((gchar *) l->data); g_list_free (ims); return dirty; } static EContactField -proto_to_contact_field (const char *proto) +proto_to_contact_field (const gchar *proto) { if (! strcmp (proto, "prpl-oscar")) return E_CONTACT_IM_AIM; @@ -296,8 +296,8 @@ get_all_blocked (xmlNodePtr node, GSList **blocked) if (child->children) get_all_blocked (child, blocked); - if (!strcmp ((const char *)child->name, "block")) { - char *name = get_node_text (child); + if (!strcmp ((const gchar *)child->name, "block")) { + gchar *name = get_node_text (child); if (name) *blocked = g_slist_prepend (*blocked, name); @@ -308,7 +308,7 @@ get_all_blocked (xmlNodePtr node, GSList **blocked) static GList * bbdb_get_gaim_buddy_list (void) { - char *blist_path; + gchar *blist_path; xmlDocPtr buddy_xml; xmlNodePtr root, child, blist; GList *buddies = NULL; @@ -324,14 +324,14 @@ bbdb_get_gaim_buddy_list (void) } root = xmlDocGetRootElement (buddy_xml); - if (strcmp ((const char *)root->name, "purple")) { + if (strcmp ((const gchar *)root->name, "purple")) { fprintf (stderr, "bbdb: Could not parse Pidgin buddy list.\n"); xmlFreeDoc (buddy_xml); return NULL; } for (child = root->children; child != NULL; child = child->next) { - if (! strcmp ((const char *)child->name, "privacy")) { + if (! strcmp ((const gchar *)child->name, "privacy")) { get_all_blocked (child, &blocked); break; } @@ -339,7 +339,7 @@ bbdb_get_gaim_buddy_list (void) blist = NULL; for (child = root->children; child != NULL; child = child->next) { - if (! strcmp ((const char *)child->name, "blist")) { + if (! strcmp ((const gchar *)child->name, "blist")) { blist = child; break; } @@ -351,7 +351,7 @@ bbdb_get_gaim_buddy_list (void) } for (child = blist->children; child != NULL; child = child->next) { - if (! strcmp ((const char *)child->name, "group")) + if (! strcmp ((const gchar *)child->name, "group")) parse_buddy_group (child, &buddies, blocked); } @@ -383,24 +383,24 @@ free_buddy_list (GList *blist) g_list_free (blist); } -static char * +static gchar * get_node_text (xmlNodePtr node) { if (node->children == NULL || node->children->content == NULL || - strcmp ((char *)node->children->name, "text")) + strcmp ((gchar *)node->children->name, "text")) return NULL; - return g_strdup ((char *)node->children->content); + return g_strdup ((gchar *)node->children->content); } -static char * +static gchar * get_buddy_icon_from_setting (xmlNodePtr setting) { - char *icon = NULL; + gchar *icon = NULL; icon = get_node_text (setting); if (icon [0] != '/') { - char *path; + gchar *path; path = g_build_path ("/", getenv ("HOME"), ".purple/icons", icon, NULL); g_free (icon); @@ -420,7 +420,7 @@ parse_contact (xmlNodePtr contact, GList **buddies, GSList *blocked) gboolean is_blocked = FALSE; for (child = contact->children; child != NULL; child = child->next) { - if (! strcmp ((const char *)child->name, "buddy")) { + if (! strcmp ((const gchar *)child->name, "buddy")) { buddy = child; break; } @@ -433,21 +433,21 @@ parse_contact (xmlNodePtr contact, GList **buddies, GSList *blocked) gb = g_new0 (GaimBuddy, 1); - gb->proto = e_xml_get_string_prop_by_name (buddy, (const unsigned char *)"proto"); + gb->proto = e_xml_get_string_prop_by_name (buddy, (const guchar *)"proto"); for (child = buddy->children; child != NULL && !is_blocked; child = child->next) { - if (! strcmp ((const char *)child->name, "setting")) { - char *setting_type; - setting_type = e_xml_get_string_prop_by_name (child, (const unsigned char *)"name"); + if (! strcmp ((const gchar *)child->name, "setting")) { + gchar *setting_type; + setting_type = e_xml_get_string_prop_by_name (child, (const guchar *)"name"); - if (! strcmp ((const char *)setting_type, "buddy_icon")) + if (! strcmp ((const gchar *)setting_type, "buddy_icon")) gb->icon = get_buddy_icon_from_setting (child); g_free (setting_type); - } else if (! strcmp ((const char *)child->name, "name")) { + } else if (! strcmp ((const gchar *)child->name, "name")) { gb->account_name = get_node_text (child); is_blocked = g_slist_find_custom (blocked, gb->account_name, (GCompareFunc)strcmp) != NULL; - } else if (! strcmp ((const char *)child->name, "alias")) + } else if (! strcmp ((const gchar *)child->name, "alias")) gb->alias = get_node_text (child); } @@ -464,7 +464,7 @@ parse_buddy_group (xmlNodePtr group, GList **buddies, GSList *blocked) xmlNodePtr child; for (child = group->children; child != NULL; child = child->next) { - if (strcmp ((const char *)child->name, "contact")) + if (strcmp ((const gchar *)child->name, "contact")) continue; parse_contact (child, buddies, blocked); diff --git a/plugins/bbdb/test-evobuddy.c b/plugins/bbdb/test-evobuddy.c index 9d14aabebe..8d8486ac73 100644 --- a/plugins/bbdb/test-evobuddy.c +++ b/plugins/bbdb/test-evobuddy.c @@ -22,7 +22,7 @@ void bbdb_sync_buddy_list (void); -int +gint main (void) { printf ("Syncing...\n"); diff --git a/plugins/bogo-junk-plugin/bf-junk-filter.c b/plugins/bogo-junk-plugin/bf-junk-filter.c index 77aa377751..105d97e245 100644 --- a/plugins/bogo-junk-plugin/bf-junk-filter.c +++ b/plugins/bogo-junk-plugin/bf-junk-filter.c @@ -73,14 +73,14 @@ GtkWidget * org_gnome_bogo_convert_unicode (struct _EPlugin *epl, struct _EConfi /* plugin fonction prototypes */ gboolean em_junk_bf_check_junk (EPlugin *ep, EMJunkHookTarget *target); -void *em_junk_bf_validate_binary (EPlugin *ep, EMJunkHookTarget *target); +gpointer em_junk_bf_validate_binary (EPlugin *ep, EMJunkHookTarget *target); void em_junk_bf_report_junk (EPlugin *ep, EMJunkHookTarget *target); void em_junk_bf_report_non_junk (EPlugin *ep, EMJunkHookTarget *target); void em_junk_bf_commit_reports (EPlugin *ep, EMJunkHookTarget *target); static gint pipe_to_bogofilter (CamelMimeMessage *msg, const gchar **argv, GError **error); /* eplugin stuff */ -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); #define EM_JUNK_BF_GCONF_DIR_LENGTH (G_N_ELEMENTS (em_junk_bf_gconf_dir) - 1) @@ -132,7 +132,7 @@ pipe_to_bogofilter (CamelMimeMessage *msg, const gchar **argv, GError **error) retry: if (camel_debug_start ("junk")) { - int i; + gint i; printf ("pipe_to_bogofilter "); for (i = 0; argv[i]; i++) @@ -221,7 +221,7 @@ em_junk_bf_setting_notify (GConfClient *gconf, GConfEntry *entry, void *data) { - const char *key; + const gchar *key; GConfValue *value; value = gconf_entry_get_value (entry); @@ -247,7 +247,7 @@ gboolean em_junk_bf_check_junk (EPlugin *ep, EMJunkHookTarget *target) { CamelMimeMessage *msg = target->m; - int rv; + gint rv; const gchar *argv[] = { em_junk_bf_binary, @@ -315,14 +315,14 @@ em_junk_bf_commit_reports (EPlugin *ep, EMJunkHookTarget *target) { } -void * +gpointer em_junk_bf_validate_binary (EPlugin *ep, EMJunkHookTarget *target) { - return g_file_test (em_junk_bf_binary, G_FILE_TEST_EXISTS) ? (void *) "1" : NULL; + return g_file_test (em_junk_bf_binary, G_FILE_TEST_EXISTS) ? (gpointer) "1" : NULL; } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { GConfClient *gconf; diff --git a/plugins/caldav/caldav-source.c b/plugins/caldav/caldav-source.c index 1dd5ae35b5..76d19a9929 100644 --- a/plugins/caldav/caldav-source.c +++ b/plugins/caldav/caldav-source.c @@ -42,8 +42,8 @@ /*****************************************************************************/ /* prototypes */ -int e_plugin_lib_enable (EPluginLib *ep, - int enable); +gint e_plugin_lib_enable (EPluginLib *ep, + gint enable); GtkWidget * oge_caldav (EPlugin *epl, EConfigHookItemFactoryData *data); @@ -65,8 +65,8 @@ ensure_caldav_source_group (ECalSourceType source_type) g_object_unref (slist); } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { if (enable) { @@ -80,17 +80,17 @@ e_plugin_lib_enable (EPluginLib *ep, int enable) } /* replaces all '@' with '%40' in str; returns newly allocated string */ -static char * -replace_at_sign (const char *str) +static gchar * +replace_at_sign (const gchar *str) { - char *res, *at; + gchar *res, *at; if (!str) return NULL; res = g_strdup (str); while (at = strchr (res, '@'), at) { - char *tmp = g_malloc0 (sizeof (char) * (1 + strlen (res) + 2)); + gchar *tmp = g_malloc0 (sizeof (char) * (1 + strlen (res) + 2)); strncpy (tmp, res, at - res); strcat (tmp, "%40"); @@ -160,8 +160,8 @@ static void location_changed (GtkEntry *editable, ESource *source) { EUri *euri; - char *ruri; - const char *uri, *username; + gchar *ruri; + const gchar *uri, *username; uri = gtk_entry_get_text (GTK_ENTRY (editable)); @@ -194,9 +194,9 @@ static void user_changed (GtkEntry *editable, ESource *source) { EUri *euri; - char *uri; - char *ruri; - const char *user; + gchar *uri; + gchar *ruri; + const gchar *user; uri = e_source_get_uri (source); user = gtk_entry_get_text (GTK_ENTRY (editable)); @@ -227,9 +227,9 @@ user_changed (GtkEntry *editable, ESource *source) static void set_refresh_time (ESource *source, GtkWidget *spin, GtkWidget *combobox) { - int time; - int item_num = 0; - const char *refresh_str = e_source_get_property (source, "refresh"); + gint time; + gint item_num = 0; + const gchar *refresh_str = e_source_get_property (source, "refresh"); time = refresh_str ? atoi (refresh_str) : 30; if (time && !(time % 10080)) { @@ -249,10 +249,10 @@ set_refresh_time (ESource *source, GtkWidget *spin, GtkWidget *combobox) gtk_spin_button_set_value (GTK_SPIN_BUTTON (spin), time); } -static char * +static gchar * get_refresh_minutes (GtkWidget *spin, GtkWidget *combobox) { - int setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); + gint setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); switch (gtk_combo_box_get_active (GTK_COMBO_BOX (combobox))) { case 0: /* minutes */ @@ -280,7 +280,7 @@ get_refresh_minutes (GtkWidget *spin, GtkWidget *combobox) static void spin_changed (GtkSpinButton *spin, ESource *source) { - char *refresh_str; + gchar *refresh_str; GtkWidget *combobox; combobox = g_object_get_data (G_OBJECT (spin), "combobox"); @@ -293,7 +293,7 @@ spin_changed (GtkSpinButton *spin, ESource *source) static void combobox_changed (GtkComboBox *combobox, ESource *source) { - char *refresh_str; + gchar *refresh_str; GtkWidget *spin; spin = g_object_get_data (G_OBJECT (combobox), "spin"); @@ -319,11 +319,11 @@ oge_caldav (EPlugin *epl, GtkWidget *luser; GtkWidget *user; GtkWidget *label, *hbox, *spin, *combobox; - char *uri; - char *username; - const char *ssl_prop; + gchar *uri; + gchar *username; + const gchar *ssl_prop; gboolean ssl_enabled; - int row; + gint row; source = t->source; group = e_source_peek_group (source); diff --git a/plugins/calendar-file/calendar-file.c b/plugins/calendar-file/calendar-file.c index 6670d23293..9d21d62688 100644 --- a/plugins/calendar-file/calendar-file.c +++ b/plugins/calendar-file/calendar-file.c @@ -34,8 +34,8 @@ e_calendar_file_dummy (EPlugin *epl, EConfigHookItemFactoryData *data) { ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; ESource *source = t->source; - char *uri_text; - const char *relative_uri; + gchar *uri_text; + const gchar *relative_uri; uri_text = e_source_get_uri (source); if (strncmp (uri_text, "file", 4)) { diff --git a/plugins/calendar-http/calendar-http.c b/plugins/calendar-http/calendar-http.c index 7814ef5ea0..e6d4aee6a2 100644 --- a/plugins/calendar-http/calendar-http.c +++ b/plugins/calendar-http/calendar-http.c @@ -72,7 +72,7 @@ static void url_changed (GtkEntry *entry, ESource *source) { EUri *uri; - char *relative_uri; + gchar *relative_uri; uri = e_uri_new (gtk_entry_get_text (GTK_ENTRY (entry))); @@ -96,10 +96,10 @@ e_calendar_http_url (EPlugin *epl, EConfigHookItemFactoryData *data) { static GtkWidget *label; GtkWidget *entry, *parent; - int row; + gint row; ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; EUri *uri; - char *uri_text; + gchar *uri_text; static GtkWidget *hidden = NULL; if (!hidden) @@ -142,9 +142,9 @@ e_calendar_http_url (EPlugin *epl, EConfigHookItemFactoryData *data) static void set_refresh_time (ESource *source, GtkWidget *spin, GtkWidget *combobox) { - int time; - int item_num = 0; - const char *refresh_str = e_source_get_property (source, "refresh"); + gint time; + gint item_num = 0; + const gchar *refresh_str = e_source_get_property (source, "refresh"); time = refresh_str ? atoi (refresh_str) : 30; if (time && !(time % 10080)) { @@ -164,10 +164,10 @@ set_refresh_time (ESource *source, GtkWidget *spin, GtkWidget *combobox) gtk_spin_button_set_value (GTK_SPIN_BUTTON (spin), time); } -static char * +static gchar * get_refresh_minutes (GtkWidget *spin, GtkWidget *combobox) { - int setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); + gint setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); switch (gtk_combo_box_get_active (GTK_COMBO_BOX (combobox))) { case 0: /* minutes */ @@ -195,7 +195,7 @@ get_refresh_minutes (GtkWidget *spin, GtkWidget *combobox) static void spin_changed (GtkSpinButton *spin, ECalConfigTargetSource *t) { - char *refresh_str; + gchar *refresh_str; GtkWidget *combobox; combobox = g_object_get_data (G_OBJECT (spin), "combobox"); @@ -208,7 +208,7 @@ spin_changed (GtkSpinButton *spin, ECalConfigTargetSource *t) static void combobox_changed (GtkComboBox *combobox, ECalConfigTargetSource *t) { - char *refresh_str; + gchar *refresh_str; GtkWidget *spin; spin = g_object_get_data (G_OBJECT (combobox), "spin"); @@ -232,11 +232,11 @@ e_calendar_http_refresh (EPlugin *epl, EConfigHookItemFactoryData *data) { static GtkWidget *label; GtkWidget *combobox, *spin, *hbox, *parent; - int row; + gint row; ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; ESource *source = t->source; EUri *uri; - char* uri_text; + gchar * uri_text; static GtkWidget *hidden = NULL; if (!hidden) @@ -297,10 +297,10 @@ e_calendar_http_secure (EPlugin *epl, EConfigHookItemFactoryData *data) { ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; GtkWidget *secure_setting, *parent; - const char *secure_prop; - int row; + const gchar *secure_prop; + gint row; EUri *uri; - char* uri_text; + gchar * uri_text; static GtkWidget *hidden = NULL; if (!hidden) @@ -358,11 +358,11 @@ e_calendar_http_auth (EPlugin *epl, EConfigHookItemFactoryData *data) { static GtkWidget *label; GtkWidget *entry, *parent; - int row; + gint row; ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; EUri *uri; - char *uri_text; - const char *username; + gchar *uri_text; + const gchar *username; static GtkWidget *hidden = NULL; if (!hidden) @@ -412,7 +412,7 @@ e_calendar_http_check (EPlugin *epl, EConfigHookPageCheckData *data) EUri *uri; gboolean ok = FALSE; ESourceGroup *group = e_source_peek_group (t->source); - char *uri_text; + gchar *uri_text; if (strncmp (e_source_group_peek_base_uri (group), "webcal", 6)) return TRUE; diff --git a/plugins/calendar-weather/calendar-weather.c b/plugins/calendar-weather/calendar-weather.c index 9354cbb0b1..694effccaa 100644 --- a/plugins/calendar-weather/calendar-weather.c +++ b/plugins/calendar-weather/calendar-weather.c @@ -43,20 +43,20 @@ GtkWidget *e_calendar_weather_refresh (EPlugin *epl, EConfigHookItemFactoryData GtkWidget *e_calendar_weather_units (EPlugin *epl, EConfigHookItemFactoryData *data); gboolean e_calendar_weather_check (EPlugin *epl, EConfigHookPageCheckData *data); void e_calendar_weather_migrate (EPlugin *epl, ECalEventTargetComponent *data); -int e_plugin_lib_enable (EPluginLib *epl, int enable); +gint e_plugin_lib_enable (EPluginLib *epl, gint enable); #define WEATHER_BASE_URI "weather://" -int -e_plugin_lib_enable (EPluginLib *epl, int enable) +gint +e_plugin_lib_enable (EPluginLib *epl, gint enable) { GList *l; gboolean found = FALSE; - const char *tmp; + const gchar *tmp; static struct { - const char *description; - const char *icon_name; + const gchar *description; + const gchar *icon_name; } categories[] = { { N_("Weather: Fog"), "weather-fog" }, { N_("Weather: Cloudy"), "weather-few-clouds" }, @@ -74,17 +74,17 @@ e_plugin_lib_enable (EPluginLib *epl, int enable) /* Add the categories icons if we don't have them. */ for (l = e_categories_get_list (); l; l = g_list_next (l)) { - if (!strcmp ((const char *)l->data, tmp)) { + if (!strcmp ((const gchar *)l->data, tmp)) { found = TRUE; break; } } if (!found) { - int i; + gint i; for (i = 0; categories[i].description; i++) { - char *filename; + gchar *filename; filename = e_icon_factory_get_icon_filename (categories[i].icon_name, GTK_ICON_SIZE_MENU); e_categories_add (_(categories[i].description), NULL, filename, FALSE); @@ -330,7 +330,7 @@ location_clicked (GtkButton *button, ESource *source) label = GTK_WIDGET (gtk_bin_get_child (GTK_BIN (button))); text = gtk_label_get_text (GTK_LABEL (label)); - if (strcmp ((const char *)text, _("None")) == 0) + if (strcmp ((const gchar *)text, _("None")) == 0) e_source_set_relative_uri (source, ""); } @@ -342,11 +342,11 @@ e_calendar_weather_location (EPlugin *epl, EConfigHookItemFactoryData *data) { static GtkWidget *label; GtkWidget *button, *parent, *text; - int row; + gint row; ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; ESource *source = t->source; EUri *uri; - char *uri_text; + gchar *uri_text; static GtkWidget *hidden; if (store == NULL) @@ -360,7 +360,7 @@ e_calendar_weather_location (EPlugin *epl, EConfigHookItemFactoryData *data) uri_text = e_source_get_uri (t->source); uri = e_uri_new (uri_text); - if (strcmp ((const char *)uri->protocol, "weather")) { + if (strcmp ((const gchar *)uri->protocol, "weather")) { e_uri_free (uri); return hidden; } @@ -399,9 +399,9 @@ e_calendar_weather_location (EPlugin *epl, EConfigHookItemFactoryData *data) static void set_refresh_time (ESource *source, GtkWidget *spin, GtkWidget *combobox) { - int time; - int item_num = 0; - const char *refresh_str = e_source_get_property (source, "refresh"); + gint time; + gint item_num = 0; + const gchar *refresh_str = e_source_get_property (source, "refresh"); time = refresh_str ? atoi (refresh_str) : 30; if (time && !(time % 10080)) { @@ -421,10 +421,10 @@ set_refresh_time (ESource *source, GtkWidget *spin, GtkWidget *combobox) gtk_spin_button_set_value (GTK_SPIN_BUTTON (spin), time); } -static char * +static gchar * get_refresh_minutes (GtkWidget *spin, GtkWidget *combobox) { - int setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); + gint setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); switch (gtk_combo_box_get_active (GTK_COMBO_BOX (combobox))) { case 0: /* minutes */ @@ -451,7 +451,7 @@ get_refresh_minutes (GtkWidget *spin, GtkWidget *combobox) static void spin_changed (GtkSpinButton *spin, ECalConfigTargetSource *t) { - char *refresh_str; + gchar *refresh_str; GtkWidget *combobox; combobox = g_object_get_data (G_OBJECT (spin), "combobox"); @@ -464,7 +464,7 @@ spin_changed (GtkSpinButton *spin, ECalConfigTargetSource *t) static void combobox_changed (GtkComboBox *combobox, ECalConfigTargetSource *t) { - char *refresh_str; + gchar *refresh_str; GtkWidget *spin; spin = g_object_get_data (G_OBJECT (combobox), "spin"); @@ -479,11 +479,11 @@ e_calendar_weather_refresh (EPlugin *epl, EConfigHookItemFactoryData *data) { static GtkWidget *label; GtkWidget *spin, *combobox, *hbox, *parent; - int row; + gint row; ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; ESource *source = t->source; EUri *uri; - char *uri_text; + gchar *uri_text; static GtkWidget *hidden = NULL; if (!hidden) @@ -495,7 +495,7 @@ e_calendar_weather_refresh (EPlugin *epl, EConfigHookItemFactoryData *data) uri_text = e_source_get_uri (t->source); uri = e_uri_new (uri_text); g_free (uri_text); - if (strcmp ((const char *)uri->protocol, "weather")) { + if (strcmp ((const gchar *)uri->protocol, "weather")) { e_uri_free (uri); return hidden; } @@ -540,13 +540,13 @@ e_calendar_weather_refresh (EPlugin *epl, EConfigHookItemFactoryData *data) static void set_units (ESource *source, GtkWidget *combobox) { - const char *format = e_source_get_property (source, "units"); + const gchar *format = e_source_get_property (source, "units"); if (format == NULL) { format = e_source_get_property (source, "temperature"); if (format == NULL) { e_source_set_property (source, "units", "metric"); gtk_combo_box_set_active (GTK_COMBO_BOX (combobox), 0); - } else if (strcmp ((const char *)format, "fahrenheit") == 0) { + } else if (strcmp ((const gchar *)format, "fahrenheit") == 0) { /* old format, convert */ e_source_set_property (source, "units", "imperial"); gtk_combo_box_set_active (GTK_COMBO_BOX (combobox), 1); @@ -555,7 +555,7 @@ set_units (ESource *source, GtkWidget *combobox) gtk_combo_box_set_active (GTK_COMBO_BOX (combobox), 0); } } else { - if (strcmp ((const char *)format, "metric") == 0) + if (strcmp ((const gchar *)format, "metric") == 0) gtk_combo_box_set_active (GTK_COMBO_BOX (combobox), 0); else gtk_combo_box_set_active (GTK_COMBO_BOX (combobox), 1); @@ -565,7 +565,7 @@ set_units (ESource *source, GtkWidget *combobox) static void units_changed (GtkComboBox *combobox, ECalConfigTargetSource *t) { - int choice = gtk_combo_box_get_active (GTK_COMBO_BOX (combobox)); + gint choice = gtk_combo_box_get_active (GTK_COMBO_BOX (combobox)); if (choice == 0) e_source_set_property (t->source, "units", "metric"); else @@ -577,11 +577,11 @@ e_calendar_weather_units (EPlugin *epl, EConfigHookItemFactoryData *data) { static GtkWidget *label; GtkWidget *combobox, *parent; - int row; + gint row; ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; ESource *source = t->source; EUri *uri; - char *uri_text; + gchar *uri_text; static GtkWidget *hidden = NULL; if (!hidden) @@ -593,7 +593,7 @@ e_calendar_weather_units (EPlugin *epl, EConfigHookItemFactoryData *data) uri_text = e_source_get_uri (t->source); uri = e_uri_new (uri_text); g_free (uri_text); - if (strcmp ((const char *)uri->protocol, "weather")) { + if (strcmp ((const gchar *)uri->protocol, "weather")) { e_uri_free (uri); return hidden; } diff --git a/plugins/copy-tool/copy-tool.c b/plugins/copy-tool/copy-tool.c index 1f33ba71db..769bd00431 100644 --- a/plugins/copy-tool/copy-tool.c +++ b/plugins/copy-tool/copy-tool.c @@ -39,17 +39,17 @@ #include "camel/camel-internet-address.h" #include "camel/camel-url.h" -void org_gnome_copy_tool_copy_address(void *ep, EMPopupTargetURI *t); +void org_gnome_copy_tool_copy_address(gpointer ep, EMPopupTargetURI *t); void -org_gnome_copy_tool_copy_address(void *ep, EMPopupTargetURI *t) +org_gnome_copy_tool_copy_address(gpointer ep, EMPopupTargetURI *t) { if (t->uri) { CamelInternetAddress *cia = camel_internet_address_new(); CamelURL *curl; GtkClipboard *clipboard; - char *addr; - const char *tmp; + gchar *addr; + const gchar *tmp; curl = camel_url_new(t->uri, NULL); camel_address_decode((CamelAddress *)cia, curl->path); diff --git a/plugins/default-source/default-source.c b/plugins/default-source/default-source.c index a3611cc730..3f2c4635d5 100644 --- a/plugins/default-source/default-source.c +++ b/plugins/default-source/default-source.c @@ -94,10 +94,10 @@ org_gnome_default_book (EPlugin *epl, EConfigHookItemFactoryData *data) return widget; } -static const char * +static const gchar * get_calendar_option_caption (ECalSourceType source_type) { - const char *res = "???"; + const gchar *res = "???"; switch (source_type) { case E_CAL_SOURCE_TYPE_EVENT: res = _("Mark as _default calendar"); break; @@ -117,7 +117,7 @@ org_gnome_default_cal (EPlugin *epl, EConfigHookItemFactoryData *data) GtkWidget *widget; ESource *source; ECalConfigTargetSource *cal_target; - int i; + gint i; if (data->old) return data->old; diff --git a/plugins/email-custom-header/email-custom-header.c b/plugins/email-custom-header/email-custom-header.c index 7b065e0de5..10d812368d 100644 --- a/plugins/email-custom-header/email-custom-header.c +++ b/plugins/email-custom-header/email-custom-header.c @@ -70,7 +70,7 @@ struct _EmailCustomHeaderOptionsDialogPrivate { GArray *email_custom_header_details; GArray *header_index_type; gint flag; - char *help_section; + gchar *help_section; }; /* epech - e-plugin email custom header*/ @@ -81,13 +81,13 @@ static void epech_dialog_dispose (GObject *object); static void epech_setup_widgets (CustomHeaderOptionsDialog *mch); static gint epech_check_existing_composer_window(gconstpointer a, gconstpointer b); static void commit_changes (ConfigData *cd); -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); GtkWidget *e_plugin_lib_get_configure_widget (EPlugin *epl); gboolean e_plugin_ui_init(GtkUIManager *ui_manager, EMsgComposer *composer); GtkWidget *org_gnome_email_custom_header_config_option (struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data); -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { return 0; } @@ -274,14 +274,14 @@ epech_get_header_list (CustomHeaderOptionsDialog *mch) } static void -epech_load_from_gconf (GConfClient *client,const char *path,CustomHeaderOptionsDialog *mch) +epech_load_from_gconf (GConfClient *client,const gchar *path,CustomHeaderOptionsDialog *mch) { EmailCustomHeaderOptionsDialogPrivate *priv; EmailCustomHeaderDetails temp_header_details= {-1, -1, NULL, NULL}; CustomSubHeader temp_header_value_details = {NULL}; GSList *header_list,*q; gchar *buffer; - char *str_colon; + gchar *str_colon; gint index,pos; priv = mch->priv; @@ -641,8 +641,8 @@ static void header_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *iter, ConfigData *cd) { GtkTreeSelection *selection; - char *keyword = NULL; - char *value = NULL; + gchar *keyword = NULL; + gchar *value = NULL; gboolean valid; selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (cd->treeview)); @@ -677,8 +677,8 @@ header_foreach_check_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIte valid = gtk_tree_model_get_iter_first (model, iter); while (valid && gtk_list_store_iter_is_valid (cd->store, iter)) { - char *keyword = NULL; - char *value = NULL; + gchar *keyword = NULL; + gchar *value = NULL; gtk_tree_model_get (model, iter, HEADER_KEY_COLUMN, &keyword, -1); /* Check if the keyword is not empty and then emit the row-changed signal (if we delete the row, then the iter gets corrupted) */ @@ -879,15 +879,15 @@ e_plugin_lib_get_configure_widget (EPlugin *epl) GtkTreeModel *model; gint index; gchar *buffer; - char *str_colon = NULL, *str1_colon = NULL; + gchar *str_colon = NULL, *str1_colon = NULL; GtkTreeViewColumn *col; - int col_pos; + gint col_pos; GConfClient *client = gconf_client_get_default(); ConfigData *cd = g_new0 (ConfigData, 1); - char *gladefile; + gchar *gladefile; gladefile = g_build_filename (EVOLUTION_GLADEDIR, "email-custom-header.glade", diff --git a/plugins/email-custom-header/email-custom-header.h b/plugins/email-custom-header/email-custom-header.h index 30e0f7061a..9bba66d655 100644 --- a/plugins/email-custom-header/email-custom-header.h +++ b/plugins/email-custom-header/email-custom-header.h @@ -82,6 +82,6 @@ GType epech_dialog_get_type (void); CustomHeaderOptionsDialog *epech_dialog_new (void); static gboolean epech_dialog_run (CustomHeaderOptionsDialog *mch, GtkWidget *parent); static void epech_get_header_list (CustomHeaderOptionsDialog *mch); -static void epech_load_from_gconf (GConfClient *client,const char *path,CustomHeaderOptionsDialog *mch); +static void epech_load_from_gconf (GConfClient *client,const gchar *path,CustomHeaderOptionsDialog *mch); #endif diff --git a/plugins/exchange-operations/exchange-account-setup.c b/plugins/exchange-operations/exchange-account-setup.c index 2c08341ef3..53af222142 100644 --- a/plugins/exchange-operations/exchange-account-setup.c +++ b/plugins/exchange-operations/exchange-account-setup.c @@ -83,7 +83,7 @@ CamelServiceAuthType camel_exchange_password_authtype = { typedef struct { gboolean state; - char *message; + gchar *message; GtkWidget *text_view; }OOFData; @@ -119,7 +119,7 @@ static void btn_chpass_clicked (GtkButton *button, gpointer data) { ExchangeAccount *account; - char *old_password, *new_password; + gchar *old_password, *new_password; ExchangeAccountResult result; account = exchange_operations_get_exchange_account (); @@ -178,8 +178,8 @@ org_gnome_exchange_settings(EPlugin *epl, EConfigHookItemFactoryData *data) EMConfigTargetAccount *target_account; ExchangeAccount *account = NULL; CamelURL *url; - const char *source_url; - char *message = NULL, *txt = NULL, *oof_message; + const gchar *source_url; + gchar *message = NULL, *txt = NULL, *oof_message; gboolean oof_state = FALSE; gint offline_status; @@ -386,7 +386,7 @@ org_gnome_exchange_settings(EPlugin *epl, EConfigHookItemFactoryData *data) } static void -print_error (const char *owa_url, E2kAutoconfigResult result) +print_error (const gchar *owa_url, E2kAutoconfigResult result) { switch (result) { @@ -430,7 +430,7 @@ print_error (const char *owa_url, E2kAutoconfigResult result) } } -static const char * +static const gchar * gal_auth_to_string (E2kAutoconfigGalAuthPref ad_auth) { switch (ad_auth) { @@ -449,9 +449,9 @@ owa_authenticate_user(GtkWidget *button, EConfig *config) E2kAutoconfigResult result; CamelURL *url=NULL; gboolean remember_password; - char *url_string, *key; - const char *source_url, *id_name, *owa_url; - char *at, *user; + gchar *url_string, *key; + const gchar *source_url, *id_name, *owa_url; + gchar *at, *user; gboolean valid = FALSE; ExchangeParams *exchange_params; GtkWidget *mailbox_entry = g_object_get_data (G_OBJECT (button), "mailbox-entry"); @@ -520,7 +520,7 @@ owa_authenticate_user(GtkWidget *button, EConfig *config) camel_url_set_param (url, "ad_auth", valid ? gal_auth_to_string (exchange_params->ad_auth) : NULL); if (mailbox_entry) { - const char *par = camel_url_get_param (url, "mailbox"); + const gchar *par = camel_url_get_param (url, "mailbox"); gtk_entry_set_text (GTK_ENTRY (mailbox_entry), par ? par : ""); } @@ -544,16 +544,16 @@ owa_authenticate_user(GtkWidget *button, EConfig *config) static void owa_editor_entry_changed(GtkWidget *entry, EConfig *config) { - const char *uri, *ssl = NULL; + const gchar *uri, *ssl = NULL; CamelURL *url, *owaurl = NULL; - char *url_string; + gchar *url_string; EMConfigTargetAccount *target = (EMConfigTargetAccount *)config->target; GtkWidget *button = g_object_get_data((GObject *)entry, "authenticate-button"); - int active = FALSE; + gint active = FALSE; /* NB: we set the button active only if we have a parsable uri entered */ - const char * target_url = e_account_get_string(target->account, E_ACCOUNT_SOURCE_URL); + const gchar * target_url = e_account_get_string(target->account, E_ACCOUNT_SOURCE_URL); if (target_url && target_url[0] != '\0') url = camel_url_new(target_url, NULL); else url = NULL; @@ -583,11 +583,11 @@ owa_editor_entry_changed(GtkWidget *entry, EConfig *config) } static void -update_mailbox_param_in_url (EAccount *account, e_account_item_t item, const char *mailbox) +update_mailbox_param_in_url (EAccount *account, e_account_item_t item, const gchar *mailbox) { CamelURL *url; - char *url_string; - const char *target_url; + gchar *url_string; + const gchar *target_url; if (!account) return; @@ -613,7 +613,7 @@ static void mailbox_editor_entry_changed (GtkWidget *entry, EConfig *config) { EMConfigTargetAccount *target; - const char *mailbox; + const gchar *mailbox; target = (EMConfigTargetAccount *)config->target; mailbox = gtk_entry_get_text (GTK_ENTRY (entry)); @@ -634,7 +634,7 @@ want_mailbox_toggled (GtkWidget *toggle, EConfig *config) if (entry) { gboolean is_active = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (toggle)); EMConfigTargetAccount *target; - const char *mailbox; + const gchar *mailbox; gtk_widget_set_sensitive (entry, is_active); @@ -646,12 +646,12 @@ want_mailbox_toggled (GtkWidget *toggle, EConfig *config) } } -static char * +static gchar * construct_owa_url (CamelURL *url) { - const char *owa_path, *use_ssl = NULL; - const char *protocol = "http", *mailbox_name; - char *owa_url; + const gchar *owa_path, *use_ssl = NULL; + const gchar *protocol = "http", *mailbox_name; + gchar *owa_url; use_ssl = camel_url_get_param (url, "use_ssl"); if (use_ssl) { @@ -677,11 +677,11 @@ GtkWidget * org_gnome_exchange_owa_url(EPlugin *epl, EConfigHookItemFactoryData *data) { EMConfigTargetAccount *target_account; - const char *source_url; - char *owa_url = NULL, *mailbox_name, *username; + const gchar *source_url; + gchar *owa_url = NULL, *mailbox_name, *username; GtkWidget *owa_entry, *mailbox_entry, *want_mailbox_check; CamelURL *url; - int row; + gint row; GtkWidget *hbox, *label, *button; target_account = (EMConfigTargetAccount *)data->config->target; @@ -716,7 +716,7 @@ org_gnome_exchange_owa_url(EPlugin *epl, EConfigHookItemFactoryData *data) /* if the host is null, then user+other info is dropped silently, force it to be kept */ if (url->host == NULL) { - char *uri; + gchar *uri; camel_url_set_host(url, ""); uri = camel_url_to_string(url, 0); @@ -734,7 +734,7 @@ org_gnome_exchange_owa_url(EPlugin *epl, EConfigHookItemFactoryData *data) if (!owa_url) { if (url->host[0] != 0) { - char *uri; + gchar *uri; /* url has hostname but not owa_url. * Account has been created using x-c-s or evo is upgraded to 2.2 @@ -818,7 +818,7 @@ gboolean org_gnome_exchange_check_options(EPlugin *epl, EConfigHookPageCheckData *data) { EMConfigTargetAccount *target = (EMConfigTargetAccount *)data->config->target; - int status = TRUE; + gint status = TRUE; /* We assume that if the host is set, then the setting is valid. The host gets set when the provider validate() call is made */ @@ -831,7 +831,7 @@ org_gnome_exchange_check_options(EPlugin *epl, EConfigHookPageCheckData *data) strcmp (data->pageid, "20.receive_options") == 0) { CamelURL *url; - const char * target_url = e_account_get_string(target->account, E_ACCOUNT_SOURCE_URL); + const gchar * target_url = e_account_get_string(target->account, E_ACCOUNT_SOURCE_URL); if (target_url && target_url[0] != '\0') url = camel_url_new(target_url, NULL); else @@ -875,7 +875,7 @@ void org_gnome_exchange_commit (EPlugin *epl, EConfigHookItemFactoryData *data) { EMConfigTargetAccount *target_account; - const char *source_url; + const gchar *source_url; CamelURL *url; gint offline_status; @@ -922,13 +922,13 @@ static void exchange_authtype_changed (GtkComboBox *dropdown, EConfig *config) { EMConfigTargetAccount *target = (EMConfigTargetAccount *)config->target; - int id = gtk_combo_box_get_active(dropdown); + gint id = gtk_combo_box_get_active(dropdown); GtkTreeModel *model; GtkTreeIter iter; CamelServiceAuthType *authtype; CamelURL *url_source, *url_transport; - const char *source_url, *transport_url; - char *source_url_string, *transport_url_string; + const gchar *source_url, *transport_url; + gchar *source_url_string, *transport_url_string; source_url = e_account_get_string (target->account, E_ACCOUNT_SOURCE_URL); @@ -969,14 +969,14 @@ GtkWidget * org_gnome_exchange_auth_section (EPlugin *epl, EConfigHookItemFactoryData *data) { EMConfigTargetAccount *target_account; - const char *source_url; - char *label_text, *exchange_account_authtype = NULL; + const gchar *source_url; + gchar *label_text, *exchange_account_authtype = NULL; CamelURL *url; GtkWidget *hbox, *button, *auth_label, *vbox, *label_hide; GtkComboBox *dropdown; GtkTreeIter iter; GtkListStore *store; - int i, active=0, auth_changed_id = 0; + gint i, active=0, auth_changed_id = 0; GList *authtypes, *l, *ll; ExchangeAccount *account; @@ -1025,7 +1025,7 @@ org_gnome_exchange_auth_section (EPlugin *epl, EConfigHookItemFactoryData *data) for (i=0, l=authtypes; l; l=l->next, i++) { CamelServiceAuthType *authtype = l->data; - int avail = TRUE; + gint avail = TRUE; if (authtypes) { for (ll = authtypes; ll; ll = g_list_next(ll)) @@ -1104,8 +1104,8 @@ org_gnome_exchange_show_folder_size_factory (EPlugin *epl, EConfigHookItemFactor GtkListStore *model; GtkVBox *vbx; GtkHBox *hbx_size; - char *folder_name, *folder_size; - int mode; + gchar *folder_name, *folder_size; + gint mode; service = CAMEL_SERVICE (camel_folder_get_parent_store (cml_folder)); if (!service) @@ -1126,7 +1126,7 @@ org_gnome_exchange_show_folder_size_factory (EPlugin *epl, EConfigHookItemFactor if (mode == OFFLINE_MODE) return NULL; - folder_name = (char*) camel_folder_get_name (cml_folder); + folder_name = (gchar *) camel_folder_get_name (cml_folder); if (!folder_name) folder_name = g_strdup ("name"); diff --git a/plugins/exchange-operations/exchange-calendar.c b/plugins/exchange-operations/exchange-calendar.c index 58af042c0c..e43d3b0531 100644 --- a/plugins/exchange-operations/exchange-calendar.c +++ b/plugins/exchange-operations/exchange-calendar.c @@ -62,7 +62,7 @@ e_exchange_calendar_get_calendars (ECalSourceType ftype) GPtrArray *folder_array; GPtrArray *calendar_list; EFolder *folder; - int i, prefix_len; + gint i, prefix_len; gchar *type; gchar *uri_prefix; gchar *tmp, *ruri; @@ -155,11 +155,11 @@ e_exchange_calendar_pcalendar (EPlugin *epl, EConfigHookItemFactoryData *data) gchar *account_name; gchar *uri_text; gchar *cal_name; - char *folder_size; - const char *rel_uri; - int row, i; + gchar *folder_size; + const gchar *rel_uri; + gint row, i; gint offline_status; - char *offline_msg; + gchar *offline_msg; GtkWidget *lbl_offline_msg; gboolean is_personal; @@ -225,7 +225,7 @@ e_exchange_calendar_pcalendar (EPlugin *epl, EConfigHookItemFactoryData *data) g_free (uri_text); if (calendar_src_exists && is_personal) { - cal_name = (gchar*) e_source_peek_name (source); + cal_name = (gchar *) e_source_peek_name (source); model = exchange_account_folder_size_get_model (account); if (model) folder_size = g_strdup_printf ("%s KB", exchange_folder_size_get_val (model, cal_name)); @@ -281,13 +281,13 @@ e_exchange_calendar_pcalendar (EPlugin *epl, EConfigHookItemFactoryData *data) if (calendar_src_exists) { gchar *uri_prefix, *sruri, *tmpruri; - int prefix_len; + gint prefix_len; GtkTreeSelection *selection; uri_prefix = g_strconcat (account->account_filename, "/;", NULL); prefix_len = strlen (uri_prefix); - tmpruri = (gchar*) rel_uri; + tmpruri = (gchar *) rel_uri; if (g_str_has_prefix (tmpruri, uri_prefix)) { sruri = g_strdup (tmpruri+prefix_len); @@ -313,12 +313,12 @@ e_exchange_calendar_check (EPlugin *epl, EConfigHookPageCheckData *data) /* FIXME - check pageid */ ECalConfigTargetSource *t = (ECalConfigTargetSource *) data->target; ESourceGroup *group; - const char *base_uri; - const char *rel_uri; + const gchar *base_uri; + const gchar *rel_uri; gint offline_status; ExchangeAccount *account; EUri *euri; - int uri_len; + gint uri_len; gchar *uri_text, *uri_string, *path, *folder_name; gboolean is_personal; @@ -381,7 +381,7 @@ e_exchange_calendar_commit (EPlugin *epl, EConfigTarget *target) ESource *source = t->source; gchar *uri_text, *gruri, *gname, *ruri, *ftype, *path, *path_prefix, *oldpath=NULL; gchar *username, *windows_domain, *authtype; - int prefix_len; + gint prefix_len; ExchangeAccount *account; ExchangeAccountFolderResult result; ExchangeConfigListenerStatus status; @@ -429,13 +429,13 @@ e_exchange_calendar_commit (EPlugin *epl, EConfigTarget *target) ftype = g_strdup ("mail"); } - gname = (gchar*) e_source_peek_name (source); - gruri = (gchar*) e_source_peek_relative_uri (source); + gname = (gchar *) e_source_peek_name (source); + gruri = (gchar *) e_source_peek_relative_uri (source); if (calendar_src_exists) { gchar *tmpruri, *uri_string, *temp_path, *prefix; EUri *euri; - int uri_len; + gint uri_len; /* sample uri_string: exchange://user;auth=NTLM@host/ */ /* sample uri_text: exchange://user;auth=NTLM@host/;personal/Calendar */ diff --git a/plugins/exchange-operations/exchange-change-password.c b/plugins/exchange-operations/exchange-change-password.c index 539bd24d3a..82382f6f9f 100644 --- a/plugins/exchange-operations/exchange-change-password.c +++ b/plugins/exchange-operations/exchange-change-password.c @@ -42,7 +42,7 @@ entry_changed (GtkEntry *entry, gpointer user_data) GladeXML *xml = user_data; GtkEntry *new_entry, *confirm_entry; GtkWidget *ok_button; - const char *text; + const gchar *text; new_entry = GTK_ENTRY (glade_xml_get_widget (xml, "new_pass_entry")); confirm_entry = GTK_ENTRY (glade_xml_get_widget (xml, "confirm_pass_entry")); @@ -71,15 +71,15 @@ entry_changed (GtkEntry *entry, gpointer user_data) * * Prompt the user for a new password. */ -char * -exchange_get_new_password (const char *existing_password, gboolean voluntary) +gchar * +exchange_get_new_password (const gchar *existing_password, gboolean voluntary) { GladeXML *xml; GtkWidget *top_widget; GtkEntry *cur_entry, *new_entry, *confirm_entry; GtkResponseType response; GtkLabel *top_label; - char *new_pass; + gchar *new_pass; xml = glade_xml_new (FILENAME, ROOTNODE, NULL); top_widget = glade_xml_get_widget (xml, ROOTNODE); @@ -100,7 +100,7 @@ exchange_get_new_password (const char *existing_password, gboolean voluntary) run_dialog_again: response = gtk_dialog_run (GTK_DIALOG (top_widget)); if (response == GTK_RESPONSE_OK) { - const char *cur_pass, *new_pass1, *new_pass2; + const gchar *cur_pass, *new_pass1, *new_pass2; cur_pass = gtk_entry_get_text (cur_entry); new_pass1 = gtk_entry_get_text (new_entry); diff --git a/plugins/exchange-operations/exchange-change-password.h b/plugins/exchange-operations/exchange-change-password.h index e320d89cf9..389922f1b3 100644 --- a/plugins/exchange-operations/exchange-change-password.h +++ b/plugins/exchange-operations/exchange-change-password.h @@ -28,7 +28,7 @@ extern "C" { #pragma } #endif /* __cplusplus */ -char *exchange_get_new_password (const char *existing_password, +gchar *exchange_get_new_password (const gchar *existing_password, gboolean voluntary); #ifdef __cplusplus diff --git a/plugins/exchange-operations/exchange-config-listener.c b/plugins/exchange-operations/exchange-config-listener.c index 5ff53fb171..35d06d527d 100644 --- a/plugins/exchange-operations/exchange-config-listener.c +++ b/plugins/exchange-operations/exchange-config-listener.c @@ -53,16 +53,16 @@ struct _ExchangeConfigListenerPrivate { GConfClient *gconf; guint idle_id; - char *configured_uri, *configured_name; + gchar *configured_uri, *configured_name; EAccount *configured_account; ExchangeAccount *exchange_account; }; typedef struct { - const char *name; - const char *uri; - int type; + const gchar *name; + const gchar *uri; + gint type; }FolderInfo; enum { @@ -96,7 +96,7 @@ static void exchange_add_autocompletion_folders (GConfClient *gc_client, static gboolean exchange_camel_urls_is_equal (const gchar *url1, const gchar *url2); static void remove_selected_non_offline_esources (ExchangeAccount *account, - const char *gconf_key); + const gchar *gconf_key); static void class_init (GObjectClass *object_class) { @@ -182,9 +182,9 @@ E2K_MAKE_TYPE (exchange_config_listener, ExchangeConfigListener, class_init, ini #define EVOLUTION_URI_PREFIX_LEN (sizeof (EVOLUTION_URI_PREFIX) - 1) static EFolder * -standard_folder (ExchangeAccount *account, const char *folder_type) +standard_folder (ExchangeAccount *account, const gchar *folder_type) { - const char *uri; + const gchar *uri; uri = exchange_account_get_standard_uri (account, folder_type); if (!uri) @@ -193,14 +193,14 @@ standard_folder (ExchangeAccount *account, const char *folder_type) } static void -set_special_mail_folder (ExchangeAccount *account, const char *folder_type, - char **folder_uri) +set_special_mail_folder (ExchangeAccount *account, const gchar *folder_type, + gchar **folder_uri) { EFolder *folder; - const char *physical_uri; - char *url_string, *path; + const gchar *physical_uri; + gchar *url_string, *path; CamelURL *camel_url; - int uri_len; + gint uri_len; folder = standard_folder (account, folder_type); if (!folder) @@ -271,12 +271,12 @@ add_account_esources (ExchangeAccount *account, ESourceGroup *cal_source_group = NULL; ESourceGroup *tasks_source_group = NULL; ESourceGroup *contacts_source_group = NULL; - char *relative_uri = NULL, *username = NULL; + gchar *relative_uri = NULL, *username = NULL; #if 0 GSList *ids; #endif GConfClient *client; - int mode; + gint mode; ESourceList *cal_source_list, *tasks_source_list, *contacts_source_list; FolderInfo *folder=NULL; gboolean offline_mode = FALSE; @@ -409,11 +409,11 @@ add_new_sources (ExchangeAccount *account) exchange_folders = exchange_account_get_folders (account); if (exchange_folders && exchange_folders->len > 0) { - int i; - const char *folder_type; - const char *folder_name; - const char *folder_uri; - int type; + gint i; + const gchar *folder_type; + const gchar *folder_name; + const gchar *folder_uri; + gint type; EFolder *folder; ExchangeHierarchy *hier; gboolean create_esource = FALSE; @@ -462,8 +462,8 @@ add_sources (ExchangeAccount *account) exchange_folders = exchange_account_get_folders (account); if (exchange_folders && exchange_folders->len > 0) { - int i; - const char *folder_type; + gint i; + const gchar *folder_type; EFolder *folder; GSList *folders = NULL; @@ -516,7 +516,7 @@ remove_account_esource (ExchangeAccount *account, GSList *sources; GSList *ids, *node_to_be_deleted; gboolean found_group; - const char *source_uid; + const gchar *source_uid; GConfClient *client; ESourceList *source_list = NULL; @@ -614,10 +614,10 @@ remove_account_esources (ExchangeAccount *account) } #ifdef HAVE_KRB5 -static char * +static gchar * get_new_exchange_password (ExchangeAccount *account) { - char *old_password, *new_password; + gchar *old_password, *new_password; old_password = exchange_account_get_password (account); new_password = exchange_get_new_password (old_password, 0); @@ -638,7 +638,7 @@ get_new_exchange_password (ExchangeAccount *account) static void change_passwd_cb (GtkWidget *button, ExchangeAccount *account) { - char *current_passwd, *new_passwd; + gchar *current_passwd, *new_passwd; gtk_widget_hide (gtk_widget_get_toplevel(button)); current_passwd = exchange_account_get_password (account); @@ -650,13 +650,13 @@ change_passwd_cb (GtkWidget *button, ExchangeAccount *account) #endif static void -display_passwd_expiry_message (int max_passwd_age, ExchangeAccount *account) +display_passwd_expiry_message (gint max_passwd_age, ExchangeAccount *account) { GladeXML *xml; GtkWidget *top_widget, *change_passwd_button; GtkResponseType response; GtkLabel *warning_msg_label; - char *passwd_expiry_msg = + gchar *passwd_expiry_msg = g_strdup_printf (_("Your password will expire in the next %d days"), max_passwd_age); xml = glade_xml_new (FILENAME, ROOTNODE, NULL); @@ -688,13 +688,13 @@ exchange_config_listener_authenticate (ExchangeConfigListener *ex_conf_listener, { ExchangeConfigListenerPrivate *priv; ExchangeAccountResult result; - char *key, *password, *title, *url_string; + gchar *key, *password, *title, *url_string; #ifdef HAVE_KRB5 - char *new_password; + gchar *new_password; #endif gboolean oldremember, remember = FALSE; CamelURL *camel_url; - const char *remember_password; + const gchar *remember_password; g_return_val_if_fail (EXCHANGE_IS_CONFIG_LISTENER (ex_conf_listener), EXCHANGE_ACCOUNT_CONFIG_ERROR); priv = ex_conf_listener->priv; @@ -752,7 +752,7 @@ exchange_config_listener_authenticate (ExchangeConfigListener *ex_conf_listener, result == EXCHANGE_ACCOUNT_QUOTA_SEND_ERROR || result == EXCHANGE_ACCOUNT_QUOTA_WARN) { gchar *current_quota_usage = NULL; - const char *error_code = NULL; + const gchar *error_code = NULL; GtkWidget *widget; switch (result) { @@ -789,7 +789,7 @@ exchange_config_listener_authenticate (ExchangeConfigListener *ex_conf_listener, result = EXCHANGE_ACCOUNT_CONNECT_SUCCESS; } if (result == EXCHANGE_ACCOUNT_CONNECT_SUCCESS) { - int max_pwd_age_days; + gint max_pwd_age_days; GladeXML *xml; GtkWidget *dialog; GtkResponseType response; @@ -905,13 +905,13 @@ configured_account_destroyed (gpointer user_data, GObject *where_account_was) } static gboolean -requires_relogin (char *current_url, char *new_url) +requires_relogin (gchar *current_url, gchar *new_url) { E2kUri *current_uri, *new_uri; - const char *current_param_val, *new_param_val; - const char *params [] = { "owa_url", "ad_server", "use_ssl" }; - const int n_params = G_N_ELEMENTS (params); - int i; + const gchar *current_param_val, *new_param_val; + const gchar *params [] = { "owa_url", "ad_server", "use_ssl" }; + const gint n_params = G_N_ELEMENTS (params); + gint i; gboolean relogin = FALSE; current_uri = e2k_uri_new (current_url); @@ -1176,8 +1176,8 @@ exchange_config_listener_get_accounts (ExchangeConfigListener *config_listener) **/ void exchange_config_listener_modify_esource_group_name (ExchangeConfigListener *excl, - const char *old_name, - const char *new_name) + const gchar *old_name, + const gchar *new_name) { GConfClient *client; ESourceGroup *group; @@ -1299,22 +1299,22 @@ exchange_camel_urls_is_equal (const gchar *url1, const gchar *url2) { CamelURL *curl1, *curl2; gchar *param1, *param2; - const char *params[] = { + const gchar *params[] = { "auth", "owa_url", "owa_path", "mailbox", "ad_server", }; - const int n_params = 5; - int i; + const gint n_params = 5; + gint i; curl1 = camel_url_new (url1, NULL); curl2 = camel_url_new (url2, NULL); for (i = 0; i < n_params; ++i) { - param1 = (gchar*) camel_url_get_param (curl1, params[i]); - param2 = (gchar*) camel_url_get_param (curl2, params[i]); + param1 = (gchar *) camel_url_get_param (curl1, params[i]); + param2 = (gchar *) camel_url_get_param (curl2, params[i]); if ((param1 && !param2) || (!param1 && param2) || /* Missing */ (param1 && param2 && strcmp (param1, param2))) { /* Differing */ g_free (param1); @@ -1342,7 +1342,7 @@ exchange_camel_urls_is_equal (const gchar *url1, const gchar *url2) * selection list **/ static void -remove_selected_non_offline_esources (ExchangeAccount *account, const char *gconf_key) +remove_selected_non_offline_esources (ExchangeAccount *account, const gchar *gconf_key) { ESourceGroup *group; ESource *source = NULL; @@ -1350,11 +1350,11 @@ remove_selected_non_offline_esources (ExchangeAccount *account, const char *gcon GSList *sources; GSList *ids, *node_to_be_deleted; gboolean found_group; - const char *source_uid; + const gchar *source_uid; GConfClient *client; ESourceList *source_list = NULL; - const char *offline_mode=NULL; - char *selected_gconf_key; + const gchar *offline_mode=NULL; + gchar *selected_gconf_key; if (gconf_key && !strcmp (gconf_key, CONF_KEY_CAL)) { diff --git a/plugins/exchange-operations/exchange-config-listener.h b/plugins/exchange-operations/exchange-config-listener.h index b5ceca2a27..3ec2d5c62f 100644 --- a/plugins/exchange-operations/exchange-config-listener.h +++ b/plugins/exchange-operations/exchange-config-listener.h @@ -71,13 +71,13 @@ ExchangeConfigListener *exchange_config_listener_new (void); GSList *exchange_config_listener_get_accounts (ExchangeConfigListener *config_listener); -void add_folder_esource (ExchangeAccount *account, FolderType folder_type, const char *folder_name, const char *physical_uri); -void remove_folder_esource (ExchangeAccount *account, FolderType folder_type, const char *physical_uri); +void add_folder_esource (ExchangeAccount *account, FolderType folder_type, const gchar *folder_name, const gchar *physical_uri); +void remove_folder_esource (ExchangeAccount *account, FolderType folder_type, const gchar *physical_uri); ExchangeConfigListenerStatus exchange_config_listener_get_offline_status (ExchangeConfigListener *excl, gint *mode); void exchange_config_listener_modify_esource_group_name (ExchangeConfigListener *excl, - const char *old_name, - const char *new_name); + const gchar *old_name, + const gchar *new_name); ExchangeAccountResult exchange_config_listener_authenticate (ExchangeConfigListener *excl, ExchangeAccount *account); diff --git a/plugins/exchange-operations/exchange-contacts.c b/plugins/exchange-operations/exchange-contacts.c index 1955f58eba..aec27f3f69 100644 --- a/plugins/exchange-operations/exchange-contacts.c +++ b/plugins/exchange-operations/exchange-contacts.c @@ -67,7 +67,7 @@ e_exchange_contacts_get_contacts (void) GPtrArray *contacts_list; EFolder *folder; - int i, prefix_len; + gint i, prefix_len; gchar *uri_prefix, *ruri; account = exchange_operations_get_exchange_account (); @@ -84,9 +84,9 @@ e_exchange_contacts_get_contacts (void) for (i=0; i<folder_array->len; ++i) { gchar *type, *tmp; folder = g_ptr_array_index (folder_array, i); - type = (gchar*) e_folder_get_type_string (folder); + type = (gchar *) e_folder_get_type_string (folder); if (!strcmp (type, "contacts")) { - tmp = (gchar*) e_folder_get_physical_uri (folder); + tmp = (gchar *) e_folder_get_physical_uri (folder); if (g_str_has_prefix (tmp, uri_prefix)) { ruri = g_strdup (tmp+prefix_len); g_ptr_array_add (contacts_list, ruri); @@ -136,14 +136,14 @@ e_exchange_contacts_pcontacts (EPlugin *epl, EConfigHookItemFactoryData *data) GPtrArray *conlist; gchar *ruri, *account_name, *uri_text; ExchangeAccount *account; - int i; - char *folder_size, *abook_name; - const char *rel_uri; - const char *uid; + gint i; + gchar *folder_size, *abook_name; + const gchar *rel_uri; + const gchar *uid; EABConfigTargetSource *t = (EABConfigTargetSource *) data->target; ESource *source = t->source; GtkWidget *lbl_offline_msg, *vb_offline_msg; - char *offline_msg; + gchar *offline_msg; gint offline_status; gboolean gal_folder = FALSE, is_personal; @@ -212,7 +212,7 @@ e_exchange_contacts_pcontacts (EPlugin *epl, EConfigHookItemFactoryData *data) g_free (uri_text); if (contacts_src_exists && is_personal ) { - abook_name = (char*)e_source_peek_name (source); + abook_name = (gchar *)e_source_peek_name (source); model = exchange_account_folder_size_get_model (account); if (model) folder_size = g_strdup_printf (_("%s KB"), exchange_folder_size_get_val (model, abook_name)); @@ -275,10 +275,10 @@ e_exchange_contacts_pcontacts (EPlugin *epl, EConfigHookItemFactoryData *data) if (contacts_src_exists) { gchar *uri_prefix, *sruri, *tmpruri; - int prefix_len; + gint prefix_len; GtkTreeSelection *selection; - tmpruri = (gchar*) rel_uri; + tmpruri = (gchar *) rel_uri; uri_prefix = g_strconcat (account->account_filename, "/;", NULL); prefix_len = strlen (uri_prefix); @@ -311,8 +311,8 @@ e_exchange_contacts_check (EPlugin *epl, EConfigHookPageCheckData *data) /* FIXME - check pageid */ EABConfigTargetSource *t = (EABConfigTargetSource *) data->target; ESourceGroup *group; - const char *base_uri; - const char *rel_uri; + const gchar *base_uri; + const gchar *rel_uri; gint offline_status; ExchangeAccount *account; @@ -375,7 +375,7 @@ e_exchange_contacts_check (EPlugin *epl, EConfigHookPageCheckData *data) } else { EUri *euri; - int uri_len; + gint uri_len; gchar *uri_text, *uri_string, *path, *folder_name; gboolean is_personal; @@ -414,7 +414,7 @@ e_exchange_contacts_commit (EPlugin *epl, EConfigTarget *target) ESource *source = t->source; gchar *uri_text, *gname, *gruri, *ruri = NULL, *path = NULL, *path_prefix, *oldpath=NULL; gchar *username, *windows_domain, *authtype; - int prefix_len; + gint prefix_len; ExchangeAccount *account; ExchangeAccountFolderResult result; gint offline_status; @@ -451,13 +451,13 @@ e_exchange_contacts_commit (EPlugin *epl, EConfigTarget *target) prefix_len = strlen (path_prefix); g_free (path_prefix); - gname = (gchar*) e_source_peek_name (source); - gruri = (gchar*) e_source_peek_relative_uri (source); + gname = (gchar *) e_source_peek_name (source); + gruri = (gchar *) e_source_peek_relative_uri (source); if (contacts_src_exists) { gchar *tmpruri, *uri_string, *temp_path, *prefix; EUri *euri; - int uri_len; + gint uri_len; euri = e_uri_new (uri_text); uri_string = e_uri_to_string (euri, FALSE); diff --git a/plugins/exchange-operations/exchange-delegates-user.c b/plugins/exchange-operations/exchange-delegates-user.c index 7de3948814..437aeec51f 100644 --- a/plugins/exchange-operations/exchange-delegates-user.c +++ b/plugins/exchange-operations/exchange-delegates-user.c @@ -54,7 +54,7 @@ * means "end of list" to e_dialog_combo_box_get/set */ -static const int exchange_perm_map[] = { +static const gint exchange_perm_map[] = { E2K_PERMISSIONS_ROLE_NONE, E2K_PERMISSIONS_ROLE_REVIEWER, E2K_PERMISSIONS_ROLE_AUTHOR, @@ -65,18 +65,18 @@ static const int exchange_perm_map[] = { -1 }; -const char *exchange_delegates_user_folder_names[] = { +const gchar *exchange_delegates_user_folder_names[] = { "calendar", "tasks", "inbox", "contacts" }; /* To translators: The folder names to be displayed in the message being sent to the delegatee. */ -static const char *folder_names_for_display[] = { +static const gchar *folder_names_for_display[] = { N_("Calendar"), N_("Tasks"), N_("Inbox"), N_("Contacts") }; -static const char *widget_names[] = { +static const gchar *widget_names[] = { "calendar_perms_combobox", "task_perms_combobox", "inbox_perms_combobox", "contact_perms_combobox", }; @@ -156,10 +156,10 @@ parent_window_destroyed (gpointer dialog, GObject *where_parent_window_was) /* Maps the role_nam parameter to their corresponding Full role name */ -static const char * +static const gchar * map_to_full_role_name (E2kPermissionsRole role_nam) { - const char *role_name; + const gchar *role_name; switch (role_nam) { @@ -187,7 +187,7 @@ map_to_full_role_name (E2kPermissionsRole role_nam) static void em_utils_delegates_done (CamelFolder *folder, CamelMimeMessage *msg, CamelMessageInfo *info, - int queued, const char *appended_uid, void *data) + gint queued, const gchar *appended_uid, gpointer data) { camel_message_info_free (info); mail_send (); @@ -211,8 +211,8 @@ exchange_delegates_user_edit (ExchangeAccount *account, { GladeXML *xml; GtkWidget *dialog, *table, *label, *combobox, *check, *check_delegate; - char *title; - int button, i; + gchar *title; + gint button, i; E2kPermissionsRole role; gboolean modified; @@ -299,13 +299,13 @@ exchange_delegates_user_edit (ExchangeAccount *account, CamelStream *stream; CamelFolder *out_folder; CamelMessageInfo *info; - char *self_address, *delegate_mail_subject; - char *role_name; + gchar *self_address, *delegate_mail_subject; + gchar *role_name; GString *role_name_final; - const char *recipient_address; - const char *delegate_exchange_dn; - const char *msg_part1 = NULL, *msg_part2 = NULL; + const gchar *recipient_address; + const gchar *delegate_exchange_dn; + const gchar *msg_part1 = NULL, *msg_part2 = NULL; role_name_final = g_string_new (""); @@ -456,10 +456,10 @@ exchange_delegates_user_edit (ExchangeAccount *account, * with most of the internal data blank). **/ ExchangeDelegatesUser * -exchange_delegates_user_new (const char *display_name) +exchange_delegates_user_new (const gchar *display_name) { ExchangeDelegatesUser *user; - int i; + gint i; user = g_object_new (EXCHANGE_TYPE_DELEGATES_USER, NULL); user->display_name = g_strdup (display_name); @@ -487,7 +487,7 @@ exchange_delegates_user_new (const char *display_name) **/ ExchangeDelegatesUser * exchange_delegates_user_new_from_gc (E2kGlobalCatalog *gc, - const char *email, + const gchar *email, GByteArray *creator_entryid) { E2kGlobalCatalogStatus status; diff --git a/plugins/exchange-operations/exchange-delegates-user.h b/plugins/exchange-operations/exchange-delegates-user.h index 251a09de9d..d1a38ca876 100644 --- a/plugins/exchange-operations/exchange-delegates-user.h +++ b/plugins/exchange-operations/exchange-delegates-user.h @@ -52,7 +52,7 @@ enum { struct _ExchangeDelegatesUser { GObject parent; - char *display_name, *dn; + gchar *display_name, *dn; GByteArray *entryid; E2kSid *sid; @@ -71,9 +71,9 @@ struct _ExchangeDelegatesUserClass { GType exchange_delegates_user_get_type (void); -ExchangeDelegatesUser *exchange_delegates_user_new (const char *display_name); +ExchangeDelegatesUser *exchange_delegates_user_new (const gchar *display_name); ExchangeDelegatesUser *exchange_delegates_user_new_from_gc (E2kGlobalCatalog *gc, - const char *email, + const gchar *email, GByteArray *creator_entryid); gboolean exchange_delegates_user_edit (ExchangeAccount *account, ExchangeDelegatesUser *user, diff --git a/plugins/exchange-operations/exchange-delegates.c b/plugins/exchange-operations/exchange-delegates.c index 4038ef0baf..f5e8891b77 100644 --- a/plugins/exchange-operations/exchange-delegates.c +++ b/plugins/exchange-operations/exchange-delegates.c @@ -47,14 +47,14 @@ #include <glade/glade-xml.h> typedef struct { - const char *uri; + const gchar *uri; E2kSecurityDescriptor *sd; gboolean changed; } ExchangeDelegatesFolder; typedef struct { ExchangeAccount *account; - char *self_dn; + gchar *self_dn; GladeXML *xml; GtkWidget *dialog, *parent; @@ -69,18 +69,18 @@ typedef struct { ExchangeDelegatesFolder freebusy_folder; } ExchangeDelegates; -extern const char *exchange_delegates_user_folder_names[]; +extern const gchar *exchange_delegates_user_folder_names[]; -const char *exchange_localfreebusy_path = "NON_IPM_SUBTREE/Freebusy%20Data/LocalFreebusy.EML"; +const gchar *exchange_localfreebusy_path = "NON_IPM_SUBTREE/Freebusy%20Data/LocalFreebusy.EML"; static void set_perms_for_user (ExchangeDelegatesUser *user, gpointer user_data); static void set_sd_for_href (ExchangeDelegates *delegates, - const char *href, + const gchar *href, E2kSecurityDescriptor *sd) { - int i; + gint i; for (i = 0; i < EXCHANGE_DELEGATES_LAST; i++) { if (!delegates->folder[i].uri) @@ -112,7 +112,7 @@ set_sd_for_href (ExchangeDelegates *delegates, static gboolean fill_in_sids (ExchangeDelegates *delegates) { - int u, u2, sd, needed_sids; + gint u, u2, sd, needed_sids; ExchangeDelegatesUser *user, *user2; GList *sids, *s; E2kSid *sid; @@ -186,11 +186,11 @@ fill_in_sids (ExchangeDelegates *delegates) return ok; } -static const char *sd_props[] = { +static const gchar *sd_props[] = { E2K_PR_EXCHANGE_SD_BINARY, E2K_PR_EXCHANGE_SD_XML }; -static const int n_sd_props = sizeof (sd_props) / sizeof (sd_props[0]); +static const gint n_sd_props = sizeof (sd_props) / sizeof (sd_props[0]); /* Read the folder security descriptors and match them up with the * list of delegates. @@ -207,7 +207,7 @@ get_folder_security (ExchangeDelegates *delegates) GByteArray *binary_form; ExchangeDelegatesUser *user; guint32 perms; - int i, u; + gint i, u; /* If we've been here before, just return the success or * failure result from last time. @@ -228,16 +228,16 @@ get_folder_security (ExchangeDelegates *delegates) delegates->folder[i].uri = exchange_account_get_standard_uri ( delegates->account, exchange_delegates_user_folder_names[i]); if (delegates->folder[i].uri) { - g_ptr_array_add (hrefs, (char *)e2k_uri_relative ( + g_ptr_array_add (hrefs, (gchar *)e2k_uri_relative ( delegates->account->home_uri, delegates->folder[i].uri)); } } - g_ptr_array_add (hrefs, (char *)exchange_localfreebusy_path); + g_ptr_array_add (hrefs, (gchar *)exchange_localfreebusy_path); iter = e2k_context_bpropfind_start ( ctx, NULL, delegates->account->home_uri, - (const char **)hrefs->pdata, hrefs->len, + (const gchar **)hrefs->pdata, hrefs->len, sd_props, n_sd_props); g_ptr_array_free (hrefs, TRUE); @@ -281,13 +281,13 @@ get_folder_security (ExchangeDelegates *delegates) } -static const char *delegation_props[] = { +static const gchar *delegation_props[] = { PR_DELEGATES_DISPLAY_NAMES, PR_DELEGATES_ENTRYIDS, PR_DELEGATES_SEE_PRIVATE, PR_CREATOR_ENTRYID }; -static const int n_delegation_props = sizeof (delegation_props) / sizeof (delegation_props[0]); +static const gint n_delegation_props = sizeof (delegation_props) / sizeof (delegation_props[0]); /* Fetch the list of delegates from the freebusy message. */ static gboolean @@ -299,7 +299,7 @@ get_user_list (ExchangeDelegates *delegates) GPtrArray *display_names, *entryids, *privflags; GByteArray *entryid; ExchangeDelegatesUser *user; - int i; + gint i; ctx = exchange_account_get_context (delegates->account); iter = e2k_context_bpropfind_start (ctx, NULL, @@ -359,7 +359,7 @@ add_remove_user (ExchangeDelegatesUser *user, GPtrArray *to_array, GPtrArray *from_array) { ExchangeDelegatesUser *match; - int i; + gint i; for (i = 0; i < from_array->len; i++) { match = from_array->pdata[i]; @@ -379,7 +379,7 @@ static void set_perms_for_user (ExchangeDelegatesUser *user, gpointer user_data) { ExchangeDelegates *delegates = user_data; - int i, role; + gint i, role; guint32 perms; for (i = 0; i < EXCHANGE_DELEGATES_LAST; i++) { @@ -401,10 +401,10 @@ add_button_clicked_cb (GtkWidget *widget, gpointer data) ExchangeDelegates *delegates = data; E2kGlobalCatalog *gc; GtkWidget *dialog, *parent_window; - const char *delegate_exchange_dn; - char *email; + const gchar *delegate_exchange_dn; + gchar *email; ExchangeDelegatesUser *user, *match; - int response, u; + gint response, u; GtkTreeIter iter; if (!get_folder_security (delegates)) @@ -478,7 +478,7 @@ get_selected_row (GtkWidget *tree_view, GtkTreeIter *iter) GtkTreeSelection *selection; GtkTreeModel *model; GtkTreePath *path; - int *indices, row; + gint *indices, row; selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (tree_view)); if (!gtk_tree_selection_get_selected (selection, &model, iter)) @@ -498,7 +498,7 @@ edit_button_clicked_cb (GtkWidget *widget, gpointer data) ExchangeDelegates *delegates = data; GtkWidget *parent_window; GtkTreeIter iter; - int row; + gint row; if (!get_folder_security (delegates)) return; @@ -512,14 +512,14 @@ edit_button_clicked_cb (GtkWidget *widget, gpointer data) parent_window); } -const char * -email_look_up (const char *delegate_legacy, ExchangeAccount *account) +const gchar * +email_look_up (const gchar *delegate_legacy, ExchangeAccount *account) { E2kGlobalCatalog *gc; E2kGlobalCatalogEntry *entry; E2kGlobalCatalogStatus status; - const char *email_id; + const gchar *email_id; gc = exchange_account_get_global_catalog (account); @@ -541,7 +541,7 @@ table_click_cb (GtkWidget *widget, GdkEventButton *event, gpointer data) ExchangeDelegates *delegates = data; GtkWidget *parent_window; GtkTreeIter iter; - int row; + gint row; if (event->type != GDK_2BUTTON_PRESS) return FALSE; @@ -565,7 +565,7 @@ remove_button_clicked_cb (GtkWidget *widget, gpointer data) ExchangeDelegates *delegates = data; ExchangeDelegatesUser *user; GtkWidget *dialog; - int row, btn, i; + gint row, btn, i; GtkTreeIter iter; if (!get_folder_security (delegates)) @@ -609,7 +609,7 @@ proppatch_sd (E2kContext *ctx, ExchangeDelegatesFolder *folder) { GByteArray *binsd; E2kProperties *props; - const char *href = ""; + const gchar *href = ""; E2kResultIter *iter; E2kResult *result; E2kHTTPStatus status; @@ -640,7 +640,7 @@ get_user_dn (E2kGlobalCatalog *gc, ExchangeDelegatesUser *user) { E2kGlobalCatalogEntry *entry; E2kGlobalCatalogStatus status; - const char *exchange_dn; + const gchar *exchange_dn; exchange_dn = e2k_entryid_to_dn (user->entryid); status = e2k_global_catalog_lookup ( @@ -663,9 +663,9 @@ delegates_apply (ExchangeDelegates *delegates) E2kContext *ctx; GPtrArray *display_names, *entryids, *privflags; GByteArray *entryid_dup; - char *error = NULL; + gchar *error = NULL; E2kProperties *props; - int i; + gint i; E2kGlobalCatalogStatus status; if (!delegates->loaded_folders) @@ -837,7 +837,7 @@ static void parent_destroyed (gpointer user_data, GObject *ex_parent); static void delegates_destroy (ExchangeDelegates *delegates) { - int i; + gint i; g_object_unref (delegates->account); @@ -879,7 +879,7 @@ delegates_destroy (ExchangeDelegates *delegates) if (delegates->freebusy_folder.sd) g_object_unref (delegates->freebusy_folder.sd); if (delegates->freebusy_folder.uri) - g_free ((char *)delegates->freebusy_folder.uri); + g_free ((gchar *)delegates->freebusy_folder.uri); if (delegates->xml) g_object_unref (delegates->xml); @@ -889,7 +889,7 @@ delegates_destroy (ExchangeDelegates *delegates) static void -dialog_response (GtkDialog *dialog, int response, gpointer user_data) +dialog_response (GtkDialog *dialog, gint response, gpointer user_data) { ExchangeDelegates *delegates = user_data; @@ -915,7 +915,7 @@ exchange_delegates (ExchangeAccount *account, GtkWidget *parent) ExchangeDelegatesUser *user; GtkTreeViewColumn *column; GtkTreeIter iter; - int i; + gint i; g_return_if_fail (GTK_IS_WIDGET (parent)); g_return_if_fail (EXCHANGE_IS_ACCOUNT (account)); diff --git a/plugins/exchange-operations/exchange-delegates.h b/plugins/exchange-operations/exchange-delegates.h index 77fc354c60..5defd27f9a 100644 --- a/plugins/exchange-operations/exchange-delegates.h +++ b/plugins/exchange-operations/exchange-delegates.h @@ -30,7 +30,7 @@ extern "C" { #endif /* __cplusplus */ void exchange_delegates (ExchangeAccount *account, GtkWidget *parent); -const char *email_look_up (const char *delegate_legacy, ExchangeAccount *account); +const gchar *email_look_up (const gchar *delegate_legacy, ExchangeAccount *account); #ifdef __cplusplus } diff --git a/plugins/exchange-operations/exchange-folder-permission.c b/plugins/exchange-operations/exchange-folder-permission.c index 63874c793a..03d7ac7aa9 100644 --- a/plugins/exchange-operations/exchange-folder-permission.c +++ b/plugins/exchange-operations/exchange-folder-permission.c @@ -47,7 +47,7 @@ #define d(x) -static void org_folder_permissions_cb (EPopup *ep, EPopupItem *p, void *data); +static void org_folder_permissions_cb (EPopup *ep, EPopupItem *p, gpointer data); void org_gnome_exchange_folder_permissions (EPlugin *ep, EMPopupTargetFolder *t); void org_gnome_exchange_menu_folder_permissions (EPlugin *ep, EMMenuTargetSelect *target); void org_gnome_exchange_calendar_permissions (EPlugin *ep, ECalPopupTargetSource *target); @@ -63,7 +63,7 @@ static EPopupItem popup_items[] = { }; static void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } @@ -72,8 +72,8 @@ void org_gnome_exchange_calendar_permissions (EPlugin *ep, ECalPopupTargetSource *target) { GSList *menus = NULL; - int i = 0, mode; - static int first =0; + gint i = 0, mode; + static gint first =0; ExchangeAccount *account = NULL; ESource *source = NULL; gchar *uri = NULL; @@ -113,8 +113,8 @@ void org_gnome_exchange_addressbook_permissions (EPlugin *ep, EABPopupTargetSource *target) { GSList *menus = NULL; - int i = 0, mode; - static int first =0; + gint i = 0, mode; + static gint first =0; ExchangeAccount *account = NULL; ESource *source = NULL; gchar *uri = NULL; @@ -152,10 +152,10 @@ void org_gnome_exchange_folder_permissions (EPlugin *ep, EMPopupTargetFolder *target) { GSList *menus = NULL; - int i = 0, mode; - static int first =0; + gint i = 0, mode; + static gint first =0; gchar *path = NULL; - char *fixed_path = NULL; + gchar *fixed_path = NULL; ExchangeAccount *account = NULL; d(g_print ("exchange-folder-permission.c: entry\n")); @@ -201,7 +201,7 @@ org_gnome_exchange_folder_permissions (EPlugin *ep, EMPopupTargetFolder *target) } static void -org_folder_permissions_cb (EPopup *ep, EPopupItem *p, void *data) +org_folder_permissions_cb (EPopup *ep, EPopupItem *p, gpointer data) { ExchangeAccount *account = NULL; EFolder *folder = NULL; @@ -223,7 +223,7 @@ org_gnome_exchange_menu_folder_permissions (EPlugin *ep, EMMenuTargetSelect *tar ExchangeAccount *account = NULL; EFolder *folder = NULL; gchar *path = NULL; - int mode; + gint mode; if (!g_str_has_prefix (target->uri, "exchange://")) return; @@ -249,7 +249,7 @@ org_gnome_exchange_menu_cal_permissions (EPlugin *ep, ECalMenuTargetSelect *targ ECalModel *model = NULL; ECal *ecal = NULL; gchar *uri = NULL; - int mode; + gint mode; if (!target) return; @@ -283,7 +283,7 @@ org_gnome_exchange_menu_tasks_permissions (EPlugin *ep, ECalMenuTargetSelect *ta ECalModel *model = NULL; ECal *ecal = NULL; gchar *uri = NULL; - int mode; + gint mode; if (!target) return; @@ -315,7 +315,7 @@ org_gnome_exchange_menu_ab_permissions (EPlugin *ep, EABMenuTargetSelect *target EFolder *folder = NULL; EBook *ebook = NULL; gchar *uri = NULL; - int mode; + gint mode; if (!target) return; diff --git a/plugins/exchange-operations/exchange-folder-size-display.c b/plugins/exchange-operations/exchange-folder-size-display.c index ff3634341a..1a916a9f1b 100644 --- a/plugins/exchange-operations/exchange-folder-size-display.c +++ b/plugins/exchange-operations/exchange-folder-size-display.c @@ -46,7 +46,7 @@ get_folder_size_func (GtkTreeModel *model, { GHashTable *info = (GHashTable *) user_data; gdouble folder_size; - char *folder_name; + gchar *folder_name; gtk_tree_model_get(model, iter, COLUMN_SIZE, &folder_size, COLUMN_NAME, &folder_name, -1); @@ -54,11 +54,11 @@ get_folder_size_func (GtkTreeModel *model, return FALSE; } -char * -exchange_folder_size_get_val (GtkListStore *model, const char *folder_name) +gchar * +exchange_folder_size_get_val (GtkListStore *model, const gchar *folder_name) { GHashTable *finfo; - char *folder_size, *fsize; + gchar *folder_size, *fsize; finfo = g_hash_table_new_full ( g_str_hash, g_str_equal, @@ -86,7 +86,7 @@ format_size_func (GtkTreeViewColumn *col, { GtkCellRendererText *cell = (GtkCellRendererText *)renderer; gdouble folder_size; - char * new_text; + gchar * new_text; gtk_tree_model_get(model, iter, COLUMN_SIZE, &folder_size, -1); @@ -108,7 +108,7 @@ exchange_folder_size_display (GtkListStore *model, GtkWidget *parent) GladeXML *xml; GtkWidget *dialog, *table; GList *l; - char *col_name; + gchar *col_name; printf ("exchange_folder_size_display called\n"); g_return_if_fail (GTK_IS_WIDGET (parent)); diff --git a/plugins/exchange-operations/exchange-folder-size-display.h b/plugins/exchange-operations/exchange-folder-size-display.h index 95c795686d..08f22c7114 100644 --- a/plugins/exchange-operations/exchange-folder-size-display.h +++ b/plugins/exchange-operations/exchange-folder-size-display.h @@ -29,7 +29,7 @@ extern "C" { #endif /* __cplusplus */ void exchange_folder_size_display (GtkListStore *model, GtkWidget *parent); -char * exchange_folder_size_get_val (GtkListStore *model, const char *folder_name); +gchar * exchange_folder_size_get_val (GtkListStore *model, const gchar *folder_name); #ifdef __cplusplus } diff --git a/plugins/exchange-operations/exchange-folder-subscription.c b/plugins/exchange-operations/exchange-folder-subscription.c index 2f72552983..6b5d2375bc 100644 --- a/plugins/exchange-operations/exchange-folder-subscription.c +++ b/plugins/exchange-operations/exchange-folder-subscription.c @@ -105,7 +105,7 @@ setup_folder_name_combo (GladeXML *glade_xml, const gchar *fname) NULL /* FIXME: Should these be translated? */ }; - int i; + gint i; combo = GTK_COMBO_BOX (glade_xml_get_widget (glade_xml, "folder-name-combo")); g_assert (GTK_IS_COMBO_BOX_ENTRY (combo)); @@ -120,10 +120,10 @@ setup_folder_name_combo (GladeXML *glade_xml, const gchar *fname) static void folder_name_entry_changed_callback (GtkEditable *editable, - void *data) + gpointer data) { GtkDialog *dialog = GTK_DIALOG (data); - const char *folder_name_text = gtk_entry_get_text (GTK_ENTRY (editable)); + const gchar *folder_name_text = gtk_entry_get_text (GTK_ENTRY (editable)); if (*folder_name_text == '\0') gtk_dialog_set_response_sensitive (dialog, GTK_RESPONSE_OK, FALSE); @@ -132,10 +132,10 @@ folder_name_entry_changed_callback (GtkEditable *editable, } static void -user_name_entry_changed_callback (GtkEditable *editable, void *data) +user_name_entry_changed_callback (GtkEditable *editable, gpointer data) { GtkDialog *dialog = GTK_DIALOG (data); - const char *user_name_text = gtk_entry_get_text (GTK_ENTRY (editable)); + const gchar *user_name_text = gtk_entry_get_text (GTK_ENTRY (editable)); if (*user_name_text == '\0') gtk_dialog_set_response_sensitive (dialog, GTK_RESPONSE_OK, FALSE); @@ -181,7 +181,7 @@ subscribe_to_folder (GtkWidget *dialog, gint response, gpointer data) { SubscriptionInfo *subscription_info = data; gchar *user_email_address = NULL, *folder_name = NULL, *path = NULL; - char *subscriber_email; + gchar *subscriber_email; EFolder *folder = NULL; EDestinationStore *destination_store; GList *destinations; @@ -292,7 +292,7 @@ create_folder_subscription_dialog (ExchangeAccount *account, const gchar *fname) GladeXML *glade_xml; GtkWidget *dialog, *ok_button; SubscriptionInfo *subscription_info; - int mode; + gint mode; exchange_account_is_offline (account, &mode); if (mode == OFFLINE_MODE) diff --git a/plugins/exchange-operations/exchange-folder.c b/plugins/exchange-operations/exchange-folder.c index 3362f0ae83..959bdec8e5 100644 --- a/plugins/exchange-operations/exchange-folder.c +++ b/plugins/exchange-operations/exchange-folder.c @@ -50,15 +50,15 @@ void org_gnome_exchange_addressbook_subscription (EPlugin *ep, EMMenuTargetSelec void org_gnome_exchange_calendar_subscription (EPlugin *ep, EMMenuTargetSelect *target); void org_gnome_exchange_tasks_subscription (EPlugin *ep, EMMenuTargetSelect *target); void org_gnome_exchange_check_subscribed (EPlugin *ep, ECalPopupTargetSource *target); -void org_gnome_exchange_folder_unsubscribe (EPopup *ep, EPopupItem *p, void *data); +void org_gnome_exchange_folder_unsubscribe (EPopup *ep, EPopupItem *p, gpointer data); void org_gnome_exchange_check_address_book_subscribed (EPlugin *ep, EABPopupTargetSource *target); -void org_gnome_exchange_folder_ab_unsubscribe (EPopup *ep, EPopupItem *p, void *data); +void org_gnome_exchange_folder_ab_unsubscribe (EPopup *ep, EPopupItem *p, gpointer data); void org_gnome_exchange_check_inbox_subscribed (EPlugin *ep, EMPopupTargetFolder *target); -void org_gnome_exchange_folder_inbox_unsubscribe (EPopup *ep, EPopupItem *p, void *data); -void popup_free (EPopup *ep, GSList *items, void *data); -void popup_inbox_free (EPopup *ep, GSList *items, void *data); -void popup_ab_free (EPopup *ep, GSList *items, void *data); -static void exchange_get_folder (char *uri, CamelFolder *folder, void *data); +void org_gnome_exchange_folder_inbox_unsubscribe (EPopup *ep, EPopupItem *p, gpointer data); +void popup_free (EPopup *ep, GSList *items, gpointer data); +void popup_inbox_free (EPopup *ep, GSList *items, gpointer data); +void popup_ab_free (EPopup *ep, GSList *items, gpointer data); +static void exchange_get_folder (gchar *uri, CamelFolder *folder, gpointer data); #define CONF_KEY_SELECTED_CAL_SOURCES "/apps/evolution/calendar/display/selected_calendars" @@ -68,20 +68,20 @@ static EPopupItem popup_inbox_items[] = { }; void -popup_inbox_free (EPopup *ep, GSList *items, void *data) +popup_inbox_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } void -org_gnome_exchange_folder_inbox_unsubscribe (EPopup *ep, EPopupItem *p, void *data) +org_gnome_exchange_folder_inbox_unsubscribe (EPopup *ep, EPopupItem *p, gpointer data) { ExchangeAccount *account = NULL; EMPopupTargetFolder *target = data; gchar *path = NULL; gchar *stored_path = NULL; - const char *inbox_uri = NULL; - const char *inbox_physical_uri = NULL; + const gchar *inbox_uri = NULL; + const gchar *inbox_physical_uri = NULL; gchar *target_uri = NULL; EFolder *inbox; ExchangeAccountFolderResult result; @@ -147,11 +147,11 @@ org_gnome_exchange_folder_inbox_unsubscribe (EPopup *ep, EPopupItem *p, void *da } static CamelFolderInfo * -ex_create_folder_info (CamelStore *store, char *name, char *uri, - int unread_count, int flags) +ex_create_folder_info (CamelStore *store, gchar *name, gchar *uri, + gint unread_count, gint flags) { CamelFolderInfo *info; - const char *path; + const gchar *path; path = strstr (uri, "://"); if (!path) @@ -170,7 +170,7 @@ ex_create_folder_info (CamelStore *store, char *name, char *uri, } static void -exchange_get_folder (char *uri, CamelFolder *folder, void *data) +exchange_get_folder (gchar *uri, CamelFolder *folder, gpointer data) { CamelStore *store; CamelException ex; @@ -206,7 +206,7 @@ void org_gnome_exchange_check_inbox_subscribed (EPlugin *ep, EMPopupTargetFolder *target) { GSList *menus = NULL; - int i = 0; + gint i = 0; ExchangeAccount *account = NULL; gchar *path = NULL; gchar *sub_folder = NULL; @@ -237,7 +237,7 @@ static EPopupItem popup_items[] = { }; void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } @@ -247,7 +247,7 @@ static EPopupItem popup_ab_items[] = { }; void -popup_ab_free (EPopup *ep, GSList *items, void *data) +popup_ab_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } @@ -256,12 +256,12 @@ void org_gnome_exchange_check_address_book_subscribed (EPlugin *ep, EABPopupTargetSource *target) { GSList *menus = NULL; - int i = 0; + gint i = 0; ESource *source = NULL; gchar *uri = NULL; gchar *path = NULL; - char *sub_folder = NULL; - const char *base_uri; + gchar *sub_folder = NULL; + const gchar *base_uri; ExchangeAccount *account = NULL; ESourceGroup *group; @@ -298,12 +298,12 @@ void org_gnome_exchange_check_subscribed (EPlugin *ep, ECalPopupTargetSource *target) { GSList *menus = NULL; - int i = 0; + gint i = 0; ESource *source = NULL; gchar *ruri = NULL; gchar *path = NULL; - char *sub_folder = NULL; - const char *base_uri; + gchar *sub_folder = NULL; + const gchar *base_uri; ExchangeAccount *account = NULL; ESourceGroup *group; @@ -335,14 +335,14 @@ org_gnome_exchange_check_subscribed (EPlugin *ep, ECalPopupTargetSource *target) } static void -unsubscribe_dialog_ab_response (GtkDialog *dialog, int response, gpointer data) +unsubscribe_dialog_ab_response (GtkDialog *dialog, gint response, gpointer data) { if (response == GTK_RESPONSE_OK) { ExchangeAccount *account = NULL; gchar *path = NULL; gchar *uri = NULL; - const char *source_uid = NULL; + const gchar *source_uid = NULL; ESourceGroup *source_group = NULL; ESource *source = NULL; EABPopupTargetSource *target = data; @@ -371,7 +371,7 @@ unsubscribe_dialog_ab_response (GtkDialog *dialog, int response, gpointer data) } static void -unsubscribe_dialog_response (GtkDialog *dialog, int response, gpointer data) +unsubscribe_dialog_response (GtkDialog *dialog, gint response, gpointer data) { if (response == GTK_RESPONSE_OK) { @@ -379,7 +379,7 @@ unsubscribe_dialog_response (GtkDialog *dialog, int response, gpointer data) ExchangeAccount *account = NULL; gchar *path = NULL; gchar *ruri = NULL; - const char *source_uid = NULL; + const gchar *source_uid = NULL; GConfClient *client; ESourceGroup *source_group = NULL; ESource *source = NULL; @@ -430,7 +430,7 @@ unsubscribe_dialog_response (GtkDialog *dialog, int response, gpointer data) } void -org_gnome_exchange_folder_ab_unsubscribe (EPopup *ep, EPopupItem *p, void *data) +org_gnome_exchange_folder_ab_unsubscribe (EPopup *ep, EPopupItem *p, gpointer data) { GtkWidget *dialog = NULL; EABPopupTargetSource *target = data; @@ -485,7 +485,7 @@ org_gnome_exchange_folder_ab_unsubscribe (EPopup *ep, EPopupItem *p, void *data) unsubscribe_dialog_ab_response (GTK_DIALOG (dialog), response, data); } void -org_gnome_exchange_folder_unsubscribe (EPopup *ep, EPopupItem *p, void *data) +org_gnome_exchange_folder_unsubscribe (EPopup *ep, EPopupItem *p, gpointer data) { GtkWidget *dialog = NULL; ECalPopupTargetSource *target = data; diff --git a/plugins/exchange-operations/exchange-mail-send-options.c b/plugins/exchange-operations/exchange-mail-send-options.c index 74d3af258e..39929eaa5b 100644 --- a/plugins/exchange-operations/exchange-mail-send-options.c +++ b/plugins/exchange-operations/exchange-mail-send-options.c @@ -44,7 +44,7 @@ append_to_header (ExchangeSendOptionsDialog *dialog, gint state, gpointer data) { EMsgComposer *composer; CamelAddress *sender_address; - const char *sender_id, *recipient_id; + const gchar *sender_id, *recipient_id; struct _camel_header_address *addr; struct _camel_header_address *sender_addr; @@ -86,7 +86,7 @@ append_to_header (ExchangeSendOptionsDialog *dialog, gint state, gpointer data) e_msg_composer_remove_header (composer, "Sensitivity"); sender_address = (CamelAddress *) e_msg_composer_get_from (composer); - sender_id = (const char*) camel_address_encode (sender_address); + sender_id = (const gchar *) camel_address_encode (sender_address); addr = camel_header_address_decode (dialog->options->delegate_address, NULL); sender_addr = camel_header_address_decode (sender_id, NULL); @@ -122,7 +122,7 @@ append_to_header (ExchangeSendOptionsDialog *dialog, gint state, gpointer data) if (dialog->options->delivery_enabled) { EComposerHeaderTable *table; EAccount *account; - char *mdn_address; + gchar *mdn_address; table = e_msg_composer_get_header_table (composer); account = e_composer_header_table_get_account (table); @@ -137,7 +137,7 @@ append_to_header (ExchangeSendOptionsDialog *dialog, gint state, gpointer data) if (dialog->options->read_enabled) { EComposerHeaderTable *table; EAccount *account; - char *mdn_address; + gchar *mdn_address; table = e_msg_composer_get_header_table (composer); account = e_composer_header_table_get_account (table); @@ -171,7 +171,7 @@ org_gnome_exchange_send_options (EPlugin *ep, EMEventTargetComposer *target) EMsgComposer *composer = target->composer; EComposerHeaderTable *table; EAccount *account = NULL; - char *temp = NULL; + gchar *temp = NULL; table = e_msg_composer_get_header_table (composer); account = e_composer_header_table_get_account (table); diff --git a/plugins/exchange-operations/exchange-operations.c b/plugins/exchange-operations/exchange-operations.c index 553a41695e..e9b8d3fd5d 100644 --- a/plugins/exchange-operations/exchange-operations.c +++ b/plugins/exchange-operations/exchange-operations.c @@ -57,8 +57,8 @@ free_exchange_listener (void) g_object_unref (exchange_global_config_listener); } -int -e_plugin_lib_enable (EPluginLib *eplib, int enable) +gint +e_plugin_lib_enable (EPluginLib *eplib, gint enable) { if (!exchange_global_config_listener) { exchange_global_config_listener = exchange_config_listener_new (); @@ -75,10 +75,10 @@ exchange_is_offline (gint *mode) /* FIXME: See if a GLib variant of this function available */ gboolean -exchange_operations_tokenize_string (char **string, char *token, char delimit, unsigned int maxsize) +exchange_operations_tokenize_string (gchar **string, gchar *token, gchar delimit, guint maxsize) { - unsigned int i=0; - char *str=*string; + guint i=0; + gchar *str=*string; while (*str!=delimit && *str!='\0' && i<maxsize-1) { token[i++]=*str++; } @@ -92,11 +92,11 @@ exchange_operations_tokenize_string (char **string, char *token, char delimit, u } gboolean -exchange_operations_cta_add_node_to_tree (GtkTreeStore *store, GtkTreeIter *parent, const char *ruri) +exchange_operations_cta_add_node_to_tree (GtkTreeStore *store, GtkTreeIter *parent, const gchar *ruri) { GtkTreeIter iter; - char *luri=(char *)ruri; - char nodename[80]; + gchar *luri=(gchar *)ruri; + gchar nodename[80]; gchar *uri; gboolean status, found; @@ -146,10 +146,10 @@ exchange_operations_cta_add_node_to_tree (GtkTreeStore *store, GtkTreeIter *pare } void -exchange_operations_cta_select_node_from_tree (GtkTreeStore *store, GtkTreeIter *parent, const char *nuri, const char *ruri, GtkTreeSelection *selection) +exchange_operations_cta_select_node_from_tree (GtkTreeStore *store, GtkTreeIter *parent, const gchar *nuri, const gchar *ruri, GtkTreeSelection *selection) { - char *luri=(char *)nuri; - char nodename[80]; + gchar *luri=(gchar *)nuri; + gchar nodename[80]; GtkTreeIter iter; gboolean status; @@ -273,7 +273,7 @@ void exchange_operations_update_child_esources (ESource *source, const gchar *ol sources = e_source_group_peek_sources (group); for (tsource = sources; tsource != NULL; tsource = tsource->next) { gchar *ruri; - ruri = (gchar*) e_source_peek_relative_uri (tsource->data); + ruri = (gchar *) e_source_peek_relative_uri (tsource->data); if (ruri && g_strrstr (ruri, old_path)) { /* This ESource points to one of the child folders */ gchar **tmpv, *truri; @@ -288,7 +288,7 @@ void exchange_operations_update_child_esources (ESource *source, const gchar *ol } gboolean -is_exchange_personal_folder (ExchangeAccount *account, char *uri) +is_exchange_personal_folder (ExchangeAccount *account, gchar *uri) { ExchangeHierarchy *hier; EFolder *folder; diff --git a/plugins/exchange-operations/exchange-operations.h b/plugins/exchange-operations/exchange-operations.h index c453b0b978..5de844ba7f 100644 --- a/plugins/exchange-operations/exchange-operations.h +++ b/plugins/exchange-operations/exchange-operations.h @@ -38,21 +38,21 @@ extern "C" { extern ExchangeConfigListener *exchange_global_config_listener; -int e_plugin_lib_enable (EPluginLib *eplib, int enable); +gint e_plugin_lib_enable (EPluginLib *eplib, gint enable); ExchangeAccount *exchange_operations_get_exchange_account (void); ExchangeConfigListenerStatus exchange_is_offline (gint *mode); -gboolean exchange_operations_tokenize_string (char **string, char *token, char delimit, unsigned int maxsize); +gboolean exchange_operations_tokenize_string (gchar **string, gchar *token, gchar delimit, guint maxsize); -gboolean exchange_operations_cta_add_node_to_tree (GtkTreeStore *store, GtkTreeIter *parent, const char *nuri); -void exchange_operations_cta_select_node_from_tree (GtkTreeStore *store, GtkTreeIter *parent, const char *nuri, const char *ruri, GtkTreeSelection *selection) ; +gboolean exchange_operations_cta_add_node_to_tree (GtkTreeStore *store, GtkTreeIter *parent, const gchar *nuri); +void exchange_operations_cta_select_node_from_tree (GtkTreeStore *store, GtkTreeIter *parent, const gchar *nuri, const gchar *ruri, GtkTreeSelection *selection) ; void exchange_operations_report_error (ExchangeAccount *account, ExchangeAccountResult result); void exchange_operations_update_child_esources (ESource *source, const gchar *old_path, const gchar *new_path); -gboolean is_exchange_personal_folder (ExchangeAccount *account, char *uri); +gboolean is_exchange_personal_folder (ExchangeAccount *account, gchar *uri); #ifdef __cplusplus } diff --git a/plugins/exchange-operations/exchange-permissions-dialog.c b/plugins/exchange-operations/exchange-permissions-dialog.c index a83d54c517..9456754377 100644 --- a/plugins/exchange-operations/exchange-permissions-dialog.c +++ b/plugins/exchange-operations/exchange-permissions-dialog.c @@ -45,7 +45,7 @@ struct _ExchangePermissionsDialogPrivate { ExchangeAccount *account; - char *base_uri, *folder_path; + gchar *base_uri, *folder_path; E2kSecurityDescriptor *sd; gboolean changed; gboolean frozen; @@ -129,13 +129,13 @@ static void get_widgets (ExchangePermissionsDialog *dialog, static void setup_user_list (ExchangePermissionsDialog *dialog); static void display_permissions (ExchangePermissionsDialog *dialog); static void dialog_response (ExchangePermissionsDialog *dialog, - int response, gpointer user_data); + gint response, gpointer user_data); -static const char *sd_props[] = { +static const gchar *sd_props[] = { E2K_PR_EXCHANGE_SD_BINARY, E2K_PR_EXCHANGE_SD_XML }; -static const int n_sd_props = sizeof (sd_props) / sizeof (sd_props[0]); +static const gint n_sd_props = sizeof (sd_props) / sizeof (sd_props[0]); /** * exchange_permissions_dialog_new: @@ -151,15 +151,15 @@ exchange_permissions_dialog_new (ExchangeAccount *account, GtkWidget *parent) { ExchangePermissionsDialog *dialog; - const char *base_uri, *folder_uri, *folder_path; + const gchar *base_uri, *folder_uri, *folder_path; E2kContext *ctx; ExchangeHierarchy *hier; GladeXML *xml; GtkWidget *box; - char *title; + gchar *title; E2kHTTPStatus status; E2kResult *results; - int nresults = 0; + gint nresults = 0; xmlNode *xml_form; GByteArray *binary_form; @@ -242,7 +242,7 @@ exchange_permissions_dialog_new (ExchangeAccount *account, } static void -dialog_response (ExchangePermissionsDialog *dialog, int response, +dialog_response (ExchangePermissionsDialog *dialog, gint response, gpointer user_data) { E2kContext *ctx; @@ -276,7 +276,7 @@ dialog_response (ExchangePermissionsDialog *dialog, int response, * folder hierarchy. #29726 */ iter = e2k_context_bproppatch_start (ctx, NULL, dialog->priv->base_uri, - (const char **)&dialog->priv->folder_path, 1, + (const gchar **)&dialog->priv->folder_path, 1, props, FALSE); e2k_properties_free (props); @@ -388,7 +388,7 @@ add_clicked (GtkButton *button, gpointer user_data) const guint8 *bsid, *bsid2; GList *email_list = NULL; GList *l = NULL; - char *email = NULL; + gchar *email = NULL; gboolean valid; gint result; @@ -525,7 +525,7 @@ static void role_changed (GtkWidget *role_combo, gpointer user_data) { ExchangePermissionsDialog *dialog = user_data; - int role; + gint role; if (dialog->priv->frozen) return; @@ -548,7 +548,7 @@ role_changed (GtkWidget *role_combo, gpointer user_data) static void display_role (ExchangePermissionsDialog *dialog) { - int role = dialog->priv->selected_role; + gint role = dialog->priv->selected_role; GtkTreeModel *model; GtkTreeIter iter; @@ -772,17 +772,17 @@ get_widgets (ExchangePermissionsDialog *dialog, GladeXML *xml) "toggled", G_CALLBACK (rv_toggle), dialog); } -GtkWidget *exchange_permissions_role_optionmenu_new (char *widget_name, char *string1, char *string2, int int1, int int2); +GtkWidget *exchange_permissions_role_optionmenu_new (gchar *widget_name, gchar *string1, gchar *string2, gint int1, gint int2); GtkWidget * -exchange_permissions_role_optionmenu_new (char *widget_name, char *string1, char *string2, int int1, int int2) +exchange_permissions_role_optionmenu_new (gchar *widget_name, gchar *string1, gchar *string2, gint int1, gint int2) { GtkWidget *menu; - const char **roles; - int role; + const gchar **roles; + gint role; menu = gtk_combo_box_new_text (); - roles = g_new (const char *, E2K_PERMISSIONS_ROLE_NUM_ROLES + 1); + roles = g_new (const gchar *, E2K_PERMISSIONS_ROLE_NUM_ROLES + 1); for (role = 0; role < E2K_PERMISSIONS_ROLE_NUM_ROLES; role++) { roles[role] = e2k_permissions_role_get_name (role); gtk_combo_box_append_text (GTK_COMBO_BOX (menu), roles[role]); diff --git a/plugins/exchange-operations/exchange-send-options.c b/plugins/exchange-operations/exchange-send-options.c index a9858d324a..783887cb24 100644 --- a/plugins/exchange-operations/exchange-send-options.c +++ b/plugins/exchange-operations/exchange-send-options.c @@ -68,7 +68,7 @@ struct _ExchangeSendOptionsDialogPrivate { /*Label Widgets*/ GtkWidget *importance_label; GtkWidget *sensitivity_label; - char *help_section; + gchar *help_section; }; static void exchange_sendoptions_dialog_class_init (GObjectClass *object_class); @@ -92,7 +92,7 @@ exchange_send_options_get_widgets_data (ExchangeSendOptionsDialog *sod) { ExchangeSendOptionsDialogPrivate *priv; ExchangeSendOptions *options; - const char *address, *email, *name; + const gchar *address, *email, *name; guint count=0; ENameSelectorEntry *name_selector_entry; @@ -120,8 +120,8 @@ exchange_send_options_get_widgets_data (ExchangeSendOptionsDialog *sod) produced ambiguous results. Hence count is used :) */ for (; tmp != NULL; tmp = g_list_next (tmp)) { - address = g_strdup ((char *) e_destination_get_address (tmp->data)); - email = g_strdup ((char *) e_destination_get_email (tmp->data)); + address = g_strdup ((gchar *) e_destination_get_address (tmp->data)); + email = g_strdup ((gchar *) e_destination_get_email (tmp->data)); name = g_strdup (e_destination_get_name (tmp->data)); if (g_str_equal (email, "")) continue; diff --git a/plugins/exchange-operations/exchange-send-options.h b/plugins/exchange-operations/exchange-send-options.h index b7bb9dd58b..8a6d37d947 100644 --- a/plugins/exchange-operations/exchange-send-options.h +++ b/plugins/exchange-operations/exchange-send-options.h @@ -60,9 +60,9 @@ typedef struct { gboolean send_as_del_enabled; gboolean delivery_enabled; gboolean read_enabled; - const char *delegate_name; - const char *delegate_email; - const char *delegate_address; + const gchar *delegate_name; + const gchar *delegate_email; + const gchar *delegate_address; } ExchangeSendOptions ; struct _ExchangeSendOptionsDialog { diff --git a/plugins/exchange-operations/exchange-user-dialog.c b/plugins/exchange-operations/exchange-user-dialog.c index 9285b9680e..3b7602f6e4 100644 --- a/plugins/exchange-operations/exchange-user-dialog.c +++ b/plugins/exchange-operations/exchange-user-dialog.c @@ -30,7 +30,7 @@ #include "e2k-xml-utils.h" struct _E2kUserDialogPrivate { - char *section_name; + gchar *section_name; ENameSelector *name_selector; GtkWidget *entry, *parent_window; }; @@ -125,8 +125,8 @@ addressbook_clicked_cb (GtkWidget *widget, gpointer data) static gboolean e2k_user_dialog_construct (E2kUserDialog *dialog, GtkWidget *parent_window, - const char *label_text, - const char *section_name) + const gchar *label_text, + const gchar *section_name) { E2kUserDialogPrivate *priv; GtkWidget *hbox, *vbox, *label, *button; @@ -197,7 +197,7 @@ e2k_user_dialog_construct (E2kUserDialog *dialog, **/ GtkWidget * e2k_user_dialog_new (GtkWidget *parent_window, - const char *label_text, const char *section_name) + const gchar *label_text, const gchar *section_name) { E2kUserDialog *dialog; @@ -243,7 +243,7 @@ e2k_user_dialog_get_user_list (E2kUserDialog *dialog) return NULL; for (l = destinations; l; l = g_list_next (l)) { - const char *mail; + const gchar *mail; destination = l->data; mail = e_destination_get_email (destination); @@ -263,7 +263,7 @@ e2k_user_dialog_get_user_list (E2kUserDialog *dialog) * * Return value: the email address, which must be freed with g_free(). **/ -char * +gchar * e2k_user_dialog_get_user (E2kUserDialog *dialog) { E2kUserDialogPrivate *priv; diff --git a/plugins/exchange-operations/exchange-user-dialog.h b/plugins/exchange-operations/exchange-user-dialog.h index 6bf191bc6e..8b6134befe 100644 --- a/plugins/exchange-operations/exchange-user-dialog.h +++ b/plugins/exchange-operations/exchange-user-dialog.h @@ -48,9 +48,9 @@ struct _E2kUserDialogClass { GType e2k_user_dialog_get_type (void); GtkWidget *e2k_user_dialog_new (GtkWidget *parent_window, - const char *label_text, - const char *section_name); -char *e2k_user_dialog_get_user (E2kUserDialog *dialog); + const gchar *label_text, + const gchar *section_name); +gchar *e2k_user_dialog_get_user (E2kUserDialog *dialog); GList *e2k_user_dialog_get_user_list (E2kUserDialog *dialog); #endif /* __E2K_USER_DIALOG_H__ */ diff --git a/plugins/external-editor/external-editor.c b/plugins/external-editor/external-editor.c index a07bb6e80e..10cfdb4fd6 100644 --- a/plugins/external-editor/external-editor.c +++ b/plugins/external-editor/external-editor.c @@ -69,7 +69,7 @@ static GThread *editor_thread; void ee_editor_command_changed (GtkWidget *textbox) { - const char *editor; + const gchar *editor; GConfClient *gconf; editor = gtk_entry_get_text (GTK_ENTRY(textbox)); @@ -101,7 +101,7 @@ e_plugin_lib_get_configure_widget (EPlugin *epl) GtkWidget *vbox, *textbox, *label, *help; GtkWidget *checkbox; GConfClient *gconf; - char *editor; + gchar *editor; gboolean checked; vbox = gtk_vbox_new (FALSE, 10); @@ -209,8 +209,8 @@ run_error_dialog (gchar *text) void async_external_editor (EMsgComposer *composer) { - char *filename = NULL; - int status = 0; + gchar *filename = NULL; + gint status = 0; GConfClient *gconf; gchar *editor_cmd_line = NULL; gint fd; diff --git a/plugins/face/face.c b/plugins/face/face.c index 1b772863a4..6bbc7bbf1a 100644 --- a/plugins/face/face.c +++ b/plugins/face/face.c @@ -50,7 +50,7 @@ action_face_cb (GtkAction *action, if (error) { GtkWidget *filesel; - const char *image_filename; + const gchar *image_filename; gsize length; GtkFileFilter *filter; @@ -89,7 +89,7 @@ action_face_cb (GtkAction *action, pixbuf = gdk_pixbuf_loader_get_pixbuf (loader); if (pixbuf) { - int width, height; + gint width, height; g_object_ref (pixbuf); diff --git a/plugins/folder-unsubscribe/folder-unsubscribe.c b/plugins/folder-unsubscribe/folder-unsubscribe.c index 308aea35f0..1d5e4fb8dc 100644 --- a/plugins/folder-unsubscribe/folder-unsubscribe.c +++ b/plugins/folder-unsubscribe/folder-unsubscribe.c @@ -46,7 +46,7 @@ void org_gnome_mail_folder_unsubscribe (EPlugin *plug, EMPopupTargetFolder *targ struct _folder_unsub_t { MailMsg base; - char *uri; + gchar *uri; }; static gchar * @@ -60,7 +60,7 @@ static void folder_unsubscribe_exec (struct _folder_unsub_t *msg) { extern CamelSession *session; - const char *path = NULL; + const gchar *path = NULL; CamelStore *store; CamelURL *url; diff --git a/plugins/google-account-setup/google-contacts-source.c b/plugins/google-account-setup/google-contacts-source.c index 23314a44cc..2253d8a7a0 100644 --- a/plugins/google-account-setup/google-contacts-source.c +++ b/plugins/google-account-setup/google-contacts-source.c @@ -83,8 +83,8 @@ static void on_username_entry_changed (GtkEntry *entry, gpointer user_data) { ESource *source = user_data; - const char *text; - char *username; + const gchar *text; + gchar *username; text = gtk_entry_get_text (entry); @@ -120,9 +120,9 @@ typedef enum { } IntervalType; static void -seconds_to_interval (guint seconds, IntervalType *type, int *time) +seconds_to_interval (guint seconds, IntervalType *type, gint *time) { - int minutes = seconds / 60; + gint minutes = seconds / 60; *type = MINUTES; *time = minutes; @@ -139,7 +139,7 @@ seconds_to_interval (guint seconds, IntervalType *type, int *time) } static guint -interval_to_seconds (IntervalType type, int time) +interval_to_seconds (IntervalType type, gint time) { switch (type) { case MINUTES: @@ -163,7 +163,7 @@ on_interval_sb_value_changed (GtkSpinButton *sb, gpointer user_data) ESource *source = user_data; gdouble time; guint seconds; - char *value_string; + gchar *value_string; GtkWidget *interval_combo; IntervalType type; @@ -185,7 +185,7 @@ on_interval_combo_changed (GtkComboBox *combo, gpointer user_data) ESource *source = user_data; gdouble time; guint seconds; - char *value_string; + gchar *value_string; GtkWidget *sb; IntervalType type; @@ -223,11 +223,11 @@ plugin_google_contacts (EPlugin *epl, EABConfigTargetSource *t = (EABConfigTargetSource *) data->target; ESource *source; ESourceGroup *group; - const char *base_uri; - const char *username; - const char *refresh_interval_str; + const gchar *base_uri; + const gchar *username; + const gchar *refresh_interval_str; guint refresh_interval; - const char *use_ssl_str; + const gchar *use_ssl_str; gboolean use_ssl; GtkWidget *parent; GtkWidget *vbox; @@ -243,7 +243,7 @@ plugin_google_contacts (EPlugin *epl, GtkWidget *interval_sb; GtkWidget *interval_combo; IntervalType type; - int time; + gint time; GtkWidget *ssl_cb; struct ui_data *ui; diff --git a/plugins/google-account-setup/google-source.c b/plugins/google-account-setup/google-source.c index 97d87c666d..cc18b0a3af 100644 --- a/plugins/google-account-setup/google-source.c +++ b/plugins/google-account-setup/google-source.c @@ -57,8 +57,8 @@ /*****************************************************************************/ /* prototypes */ -int e_plugin_lib_enable (EPluginLib *ep, - int enable); +gint e_plugin_lib_enable (EPluginLib *ep, + gint enable); GtkWidget * plugin_google (EPlugin *epl, EConfigHookItemFactoryData *data); @@ -82,8 +82,8 @@ ensure_google_source_group (void) g_object_unref (slist); } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { if (enable) { @@ -114,22 +114,22 @@ ssl_changed (GtkToggleButton *button, ESource *source) static gboolean -is_email (const char *address) +is_email (const gchar *address) { /* This is supposed to check if the address's domain could be an FQDN but alas, it's not worth the pain and suffering. */ - const char *at; + const gchar *at; at = strchr (address, '@'); - /* make sure we have an '@' and that it's not the first or last char */ + /* make sure we have an '@' and that it's not the first or last gchar */ if (!at || at == address || *(at + 1) == '\0') return FALSE; return TRUE; } -static char * -sanitize_user_mail (const char *user) +static gchar * +sanitize_user_mail (const gchar *user) { if (!user) return NULL; @@ -137,8 +137,8 @@ sanitize_user_mail (const char *user) if (!is_email (user)) { return g_strconcat (user, "%40gmail.com", NULL); } else { - char *tmp = g_malloc0 (sizeof (char) * (1 + strlen (user) + 2)); - char *at = strchr (user, '@'); + gchar *tmp = g_malloc0 (sizeof (char) * (1 + strlen (user) + 2)); + gchar *at = strchr (user, '@'); strncpy (tmp, user, at - user); strcat (tmp, "%40"); @@ -148,10 +148,10 @@ sanitize_user_mail (const char *user) } } -static char * -construct_default_uri (const char *username) +static gchar * +construct_default_uri (const gchar *username) { - char *user, *uri; + gchar *user, *uri; user = sanitize_user_mail (username); uri = g_strconcat (CALENDAR_LOCATION, user, CALENDAR_DEFAULT_PATH, NULL); @@ -162,10 +162,10 @@ construct_default_uri (const char *username) /* checks whether the given_uri is pointing to the default user's calendar or not */ static gboolean -is_default_uri (const char *given_uri, const char *username) +is_default_uri (const gchar *given_uri, const gchar *username) { - char *uri, *at; - int ats; + gchar *uri, *at; + gint ats; gboolean res; if (!given_uri) @@ -182,8 +182,8 @@ is_default_uri (const char *given_uri, const char *username) if (!ats) res = g_ascii_strcasecmp (given_uri, uri) == 0; else { - const char *last; - char *tmp = g_malloc0 (sizeof (char) * (1 + strlen (given_uri) + (2 * ats))); + const gchar *last; + gchar *tmp = g_malloc0 (sizeof (char) * (1 + strlen (given_uri) + (2 * ats))); last = given_uri; for (at = strchr (last, '@'); at; at = strchr (at + 1, '@')) { @@ -203,13 +203,13 @@ is_default_uri (const char *given_uri, const char *username) return res; } -static void init_combo_values (GtkComboBox *combo, const char *deftitle, const char *defuri); +static void init_combo_values (GtkComboBox *combo, const gchar *deftitle, const gchar *defuri); static void user_changed (GtkEntry *editable, ESource *source) { - char *uri; - const char *user; + gchar *uri; + const gchar *user; /* two reasons why set readonly to FALSE: a) the e_source_set_relative_uri does nothing for readonly sources @@ -232,10 +232,10 @@ user_changed (GtkEntry *editable, ESource *source) init_combo_values (GTK_COMBO_BOX (g_object_get_data (G_OBJECT (editable), "CalendarCombo")), _("Default"), NULL); } -static char * +static gchar * get_refresh_minutes (GtkWidget *spin, GtkWidget *combobox) { - int setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); + gint setting = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (spin)); switch (gtk_combo_box_get_active (GTK_COMBO_BOX (combobox))) { case 0: /* minutes */ @@ -289,9 +289,9 @@ combobox_changed (GtkComboBox *combobox, ECalConfigTargetSource *t) static void set_refresh_time (ESource *source, GtkWidget *spin, GtkWidget *combobox) { - int time; - int item_num = 0; - const char *refresh_str = e_source_get_property (source, "refresh"); + gint time; + gint item_num = 0; + const gchar *refresh_str = e_source_get_property (source, "refresh"); time = refresh_str ? atoi (refresh_str) : 30; if (time && !(time % 10080)) { @@ -320,7 +320,7 @@ enum { }; static void -init_combo_values (GtkComboBox *combo, const char *deftitle, const char *defuri) +init_combo_values (GtkComboBox *combo, const gchar *deftitle, const gchar *defuri) { GtkTreeIter iter; GtkListStore *store; @@ -355,7 +355,7 @@ cal_combo_changed (GtkComboBox *combo, ESource *source) store = GTK_LIST_STORE (gtk_combo_box_get_model (combo)); if (gtk_combo_box_get_active_iter (combo, &iter)) { - char *uri = NULL, *title = NULL; + gchar *uri = NULL, *title = NULL; gboolean readonly = FALSE; gtk_tree_model_get (GTK_TREE_MODEL (store), &iter, COL_TITLE, &title, COL_URL_PATH, &uri, COL_READ_ONLY, &readonly, -1); @@ -383,7 +383,7 @@ cal_combo_changed (GtkComboBox *combo, ESource *source) } static void -claim_error (GtkWindow *parent, const char *error) +claim_error (GtkWindow *parent, const gchar *error) { GtkWidget *dialog; @@ -403,8 +403,8 @@ retrieve_list_clicked (GtkButton *button, GtkComboBox *combo) ESource *source; GDataGoogleService *service; GDataFeed *feed; - char *password, *tmp; - const char *username; + gchar *password, *tmp; + const gchar *username; GError *error = NULL; GtkWindow *parent; @@ -438,8 +438,8 @@ retrieve_list_clicked (GtkButton *button, GtkComboBox *combo) if (feed) { GSList *l; - char *old_selected = NULL; - int idx, active = -1, default_idx = -1; + gchar *old_selected = NULL; + gint idx, active = -1, default_idx = -1; GtkListStore *store = GTK_LIST_STORE (gtk_combo_box_get_model (combo)); GtkTreeIter iter; @@ -449,7 +449,7 @@ retrieve_list_clicked (GtkButton *button, GtkComboBox *combo) gtk_list_store_clear (store); for (l = gdata_feed_get_entries (feed), idx = 1; l != NULL; l = l->next) { - const char *uri, *title, *color, *access; + const gchar *uri, *title, *color, *access; GSList *links; GDataEntry *entry = (GDataEntry *) l->data; @@ -559,11 +559,11 @@ plugin_google (EPlugin *epl, GtkWidget *user; GtkWidget *label; GtkWidget *combo; - char *uri; - const char *username; - const char *ssl_prop; + gchar *uri; + const gchar *username; + const gchar *ssl_prop; gboolean ssl_enabled; - int row; + gint row; GtkCellRenderer *renderer; GtkListStore *store; diff --git a/plugins/groupwise-account-setup/camel-gw-listener.c b/plugins/groupwise-account-setup/camel-gw-listener.c index 3d1fb15214..46beaac0b8 100644 --- a/plugins/groupwise-account-setup/camel-gw-listener.c +++ b/plugins/groupwise-account-setup/camel-gw-listener.c @@ -45,9 +45,9 @@ struct _CamelGwListenerPrivate { }; struct _GwAccountInfo { - char *uid; - char *name; - char *source_url; + gchar *uid; + gchar *name; + gchar *source_url; gboolean auto_check; guint auto_check_time; }; @@ -139,11 +139,11 @@ is_groupwise_account (EAccount *account) /* looks up for an existing groupwise account info in the groupwise_accounts list based on uid */ static GwAccountInfo* -lookup_account_info (const char *key) +lookup_account_info (const gchar *key) { GList *list; GwAccountInfo *info ; - int found = 0; + gint found = 0; if (!key) return NULL; @@ -169,7 +169,7 @@ lookup_account_info (const char *key) #define SELECTED_NOTES "/apps/evolution/calendar/memos/selected_memos" static void -add_esource (const char *conf_key, GwAccountInfo *info, const char *source_name, CamelURL *url, const char* parent_id_name, gboolean can_create) +add_esource (const gchar *conf_key, GwAccountInfo *info, const gchar *source_name, CamelURL *url, const gchar * parent_id_name, gboolean can_create) { ESourceList *source_list; ESourceGroup *group; @@ -177,12 +177,12 @@ add_esource (const char *conf_key, GwAccountInfo *info, const char *source_name GConfClient* client; GSList *ids, *temp ; const gchar *source_selection_key; - char *relative_uri; - const char *soap_port; - const char * use_ssl; - const char *poa_address; - const char *offline_sync; - const char *group_name; + gchar *relative_uri; + const gchar *soap_port; + const gchar * use_ssl; + const gchar *poa_address; + const gchar *offline_sync; + const gchar *group_name; poa_address = url->host; if (!poa_address || strlen (poa_address) ==0) @@ -220,7 +220,7 @@ add_esource (const char *conf_key, GwAccountInfo *info, const char *source_name e_source_set_property (source, "use_ssl", use_ssl); if (info->auto_check) { - char *str = g_strdup_printf ("%d", info->auto_check_time); + gchar *str = g_strdup_printf ("%d", info->auto_check_time); e_source_set_property (source, "refresh", str); g_free (str); @@ -266,7 +266,7 @@ add_esource (const char *conf_key, GwAccountInfo *info, const char *source_name } static void -remove_esource (const char *conf_key, const char *group_name, char* source_name, const char* relative_uri) +remove_esource (const gchar *conf_key, const gchar *group_name, gchar * source_name, const gchar * relative_uri) { ESourceList *list; GSList *groups; @@ -338,17 +338,17 @@ remove_esource (const char *conf_key, const char *group_name, char* source_name, /* looks up for e-source with having same info as old_account_info and changes its values passed in new values */ static void -modify_esource (const char* conf_key, GwAccountInfo *old_account_info, EAccount *a, CamelURL *new_url) +modify_esource (const gchar * conf_key, GwAccountInfo *old_account_info, EAccount *a, CamelURL *new_url) { ESourceList *list; GSList *groups; - char *old_relative_uri; + gchar *old_relative_uri; CamelURL *url; gboolean found_group; GConfClient* client; - const char *poa_address; - const char *new_poa_address; - const char* new_group_name = a->name; + const gchar *poa_address; + const gchar *new_poa_address; + const gchar * new_group_name = a->name; url = camel_url_new (old_account_info->source_url, NULL); poa_address = url->host; @@ -389,7 +389,7 @@ modify_esource (const char* conf_key, GwAccountInfo *old_account_info, EAccount e_source_set_property (source, "offline_sync", camel_url_get_param (url, "offline_sync") ? "1" : "0"); if (a->source->auto_check) { - char *str = g_strdup_printf ("%d", a->source->auto_check_time); + gchar *str = g_strdup_printf ("%d", a->source->auto_check_time); e_source_set_property (source, "refresh", str); g_free (str); @@ -437,9 +437,9 @@ static void remove_calendar_tasks_sources (GwAccountInfo *info) { CamelURL *url; - char *relative_uri; - const char *soap_port; - const char *poa_address; + gchar *relative_uri; + const gchar *soap_port; + const gchar *poa_address; url = camel_url_new (info->source_url, NULL); @@ -462,22 +462,22 @@ remove_calendar_tasks_sources (GwAccountInfo *info) } static GList* -get_addressbook_names_from_server (char *source_url) +get_addressbook_names_from_server (gchar *source_url) { - char *key; + gchar *key; EGwConnection *cnc; - char *password; + gchar *password; GList *book_list = NULL; - int status, count = 0; - const char *soap_port; + gint status, count = 0; + const gchar *soap_port; CamelURL *url; gboolean remember; - char *failed_auth = NULL; - char *prompt; - char *password_prompt; - char *uri; - const char *use_ssl; - const char *poa_address; + gchar *failed_auth = NULL; + gchar *prompt; + gchar *password_prompt; + gchar *uri; + const gchar *use_ssl; + const gchar *poa_address; guint32 flags = E_PASSWORDS_REMEMBER_FOREVER|E_PASSWORDS_SECRET; url = camel_url_new (source_url, NULL); @@ -552,10 +552,10 @@ get_addressbook_names_from_server (char *source_url) } static void -add_proxy_sources (GwAccountInfo *info, const char *parent_name) +add_proxy_sources (GwAccountInfo *info, const gchar *parent_name) { CamelURL *url; - char *color; + gchar *color; url = camel_url_new (info->source_url, NULL); @@ -580,12 +580,12 @@ add_addressbook_sources (EAccount *account) ESourceList *list; ESourceGroup *group; ESource *source; - char *base_uri; - const char *soap_port; + gchar *base_uri; + const gchar *soap_port; GList *books_list, *temp_list; GConfClient* client; - const char* use_ssl; - const char *poa_address; + const gchar * use_ssl; + const gchar *poa_address; gboolean is_frequent_contacts = FALSE, is_writable = FALSE; url = camel_url_new (account->source->url, NULL); @@ -610,7 +610,7 @@ add_addressbook_sources (EAccount *account) if (!temp_list) return FALSE; for (; temp_list != NULL; temp_list = g_list_next (temp_list)) { - const char *book_name = e_gw_container_get_name (E_GW_CONTAINER(temp_list->data)); + const gchar *book_name = e_gw_container_get_name (E_GW_CONTAINER(temp_list->data)); /* is_writable is set to TRUE if the book has isPersonal property, * by e_gw_connection_get_address_book_list() */ @@ -673,14 +673,14 @@ modify_addressbook_sources ( EAccount *account, GwAccountInfo *existing_account_ GSList *groups; gboolean found_group; gboolean delete_group; - char *old_base_uri; - char *new_base_uri; - const char *soap_port; - const char *use_ssl; + gchar *old_base_uri; + gchar *new_base_uri; + const gchar *soap_port; + const gchar *use_ssl; GSList *sources; ESource *source; GConfClient *client; - const char *poa_address; + const gchar *poa_address; url = camel_url_new (existing_account_info->source_url, NULL); @@ -758,10 +758,10 @@ remove_addressbook_sources (GwAccountInfo *existing_account_info) GSList *groups; gboolean found_group; CamelURL *url; - char *base_uri; - const char *soap_port; + gchar *base_uri; + const gchar *soap_port; GConfClient *client; - const char *poa_address; + const gchar *poa_address; url = camel_url_new (existing_account_info->source_url, NULL); if (url == NULL) { @@ -863,10 +863,10 @@ account_changed (EAccountList *account_listener, EAccount *account) { gboolean is_gw_account; CamelURL *old_url, *new_url; - const char *old_soap_port, *new_soap_port; + const gchar *old_soap_port, *new_soap_port; GwAccountInfo *existing_account_info; - const char *old_use_ssl, *new_use_ssl; - const char *old_poa_address, *new_poa_address; + const gchar *old_use_ssl, *new_use_ssl; + const gchar *old_poa_address, *new_poa_address; is_gw_account = is_groupwise_account (account); @@ -953,7 +953,7 @@ prune_proxies (void) { ESource *source; GError *err = NULL; const gchar *parent_id_name = NULL; - int i; + gint i; ECalSourceType types [] = { E_CAL_SOURCE_TYPE_EVENT, E_CAL_SOURCE_TYPE_TODO, E_CAL_SOURCE_TYPE_JOURNAL diff --git a/plugins/groupwise-account-setup/groupwise-account-setup.c b/plugins/groupwise-account-setup/groupwise-account-setup.c index aee5e90623..71bb1ee31e 100644 --- a/plugins/groupwise-account-setup/groupwise-account-setup.c +++ b/plugins/groupwise-account-setup/groupwise-account-setup.c @@ -32,7 +32,7 @@ static CamelGwListener *config_listener = NULL; -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); GtkWidget* org_gnome_gw_account_setup(struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data); void ensure_mandatory_esource_properties (EPlugin *ep, ESEventTargetUpgrade *target); @@ -47,7 +47,7 @@ is_groupwise_account (EAccount *account) } static void -set_esource_props (const char *path, EAccount *a, GConfClient *client, const char *name) +set_esource_props (const gchar *path, EAccount *a, GConfClient *client, const gchar *name) { ESourceList *list; GSList *groups; @@ -66,7 +66,7 @@ set_esource_props (const char *path, EAccount *a, GConfClient *client, const cha ESource *source = E_SOURCE (sources->data); if (a->source->auto_check) { - char *str = g_strdup_printf ("%d",a->source->auto_check_time); + gchar *str = g_strdup_printf ("%d",a->source->auto_check_time); e_source_set_property (source, "refresh", str); g_free (str); @@ -113,8 +113,8 @@ free_groupwise_listener ( void ) g_object_unref (config_listener); } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { if (!config_listener) { config_listener = camel_gw_listener_new (); diff --git a/plugins/groupwise-features/addressbook-groupwise.c b/plugins/groupwise-features/addressbook-groupwise.c index b6519c636e..ae0c5e1e8a 100644 --- a/plugins/groupwise-features/addressbook-groupwise.c +++ b/plugins/groupwise-features/addressbook-groupwise.c @@ -34,9 +34,9 @@ commit_groupwise_addressbook (EPlugin *epl, EConfigTarget *target) { EABConfigTargetSource *t = (EABConfigTargetSource *) target; ESource *source = t->source; - char *uri_text; + gchar *uri_text; ESourceGroup *source_group; - char *relative_uri; + gchar *relative_uri; GSList *l; uri_text = e_source_get_uri (source); diff --git a/plugins/groupwise-features/install-shared.c b/plugins/groupwise-features/install-shared.c index 29c5ed2855..c9d4ad54e4 100644 --- a/plugins/groupwise-features/install-shared.c +++ b/plugins/groupwise-features/install-shared.c @@ -57,17 +57,17 @@ struct AcceptData { void org_gnome_popup_wizard (EPlugin *ep, EMEventTargetMessage *target); static void -install_folder_response (EMFolderSelector *emfs, int response, gpointer *data) +install_folder_response (EMFolderSelector *emfs, gint response, gpointer *data) { struct AcceptData *accept_data = (struct AcceptData *)data; EMFolderTreeModel *model; - const char *uri, *path; - int parts = 0; + const gchar *uri, *path; + gint parts = 0; gchar **names; gchar *folder_name; gchar *parent_name; gchar *container_id; - const char *item_id; + const gchar *item_id; CamelException ex; CamelStore *store; CamelFolder *folder; @@ -106,12 +106,12 @@ install_folder_response (EMFolderSelector *emfs, int response, gpointer *data) if(E_IS_GW_CONNECTION (cnc)) { container_id = get_container_id (cnc, parent_name); - if(e_gw_connection_accept_shared_folder (cnc, folder_name, container_id, (char *)item_id, NULL) == E_GW_CONNECTION_STATUS_OK) { + if(e_gw_connection_accept_shared_folder (cnc, folder_name, container_id, (gchar *)item_id, NULL) == E_GW_CONNECTION_STATUS_OK) { folder = camel_store_get_folder (store, "Mailbox", 0, NULL); /*changes = camel_folder_change_info_new (); - camel_folder_change_info_remove_uid (changes, (char *) item_id); + camel_folder_change_info_remove_uid (changes, (gchar *) item_id); camel_folder_summary_remove_uid (folder->summary, item_id);*/ /* camel_folder_delete_message (folder, item_id); */ camel_folder_set_message_flags (folder, item_id, CAMEL_MESSAGE_DELETED, CAMEL_MESSAGE_DELETED); @@ -146,7 +146,7 @@ install_folder_response (EMFolderSelector *emfs, int response, gpointer *data) } static void -accept_free(void *data) +accept_free(gpointer data) { struct AcceptData *accept_data = data; @@ -161,7 +161,7 @@ accept_clicked(GnomeDruidPage *page, GtkWidget *druid, CamelMimeMessage *msg) EMFolderTree *folder_tree; GtkWidget *dialog; struct AcceptData *accept_data; - char *uri; + gchar *uri; accept_data = g_new0(struct AcceptData, 1); model = mail_component_peek_tree_model (NULL); @@ -186,20 +186,20 @@ void org_gnome_popup_wizard (EPlugin *ep, EMEventTargetMessage *target) { const CamelInternetAddress *from_addr = NULL; - const char *name; - const char *email; + const gchar *name; + const gchar *email; GtkWidget *window; GnomeDruid *wizard; GnomeDruidPageEdge *title_page; CamelMimeMessage *msg = (CamelMimeMessage *) target->message; CamelStreamMem *content; CamelDataWrapper *dw; - char *start_message; + gchar *start_message; if (!msg) return; - if (((char *)camel_medium_get_header (CAMEL_MEDIUM(msg),"X-notification")) == NULL + if (((gchar *)camel_medium_get_header (CAMEL_MEDIUM(msg),"X-notification")) == NULL || (from_addr = camel_mime_message_get_from ((CamelMimeMessage *)target->message)) == NULL || !camel_internet_address_get(from_addr, 0, &name, &email) || (dw = camel_medium_get_content_object (CAMEL_MEDIUM (msg))) == NULL) { diff --git a/plugins/groupwise-features/junk-mail-settings.c b/plugins/groupwise-features/junk-mail-settings.c index 3e7d522c19..aa8c96368d 100644 --- a/plugins/groupwise-features/junk-mail-settings.c +++ b/plugins/groupwise-features/junk-mail-settings.c @@ -52,7 +52,7 @@ abort_changes (JunkSettings *js) } static void -junk_dialog_response (GtkWidget *dialog, int response, JunkSettings *js) +junk_dialog_response (GtkWidget *dialog, gint response, JunkSettings *js) { if (response == GTK_RESPONSE_ACCEPT) { commit_changes(js); @@ -66,11 +66,11 @@ junk_dialog_response (GtkWidget *dialog, int response, JunkSettings *js) } static void -junk_mail_settings (EPopup *ep, EPopupItem *item, void *data) +junk_mail_settings (EPopup *ep, EPopupItem *item, gpointer data) { GtkWidget *dialog ,*w, *notebook, *box; JunkSettings *junk_tab; - int page_count =0; + gint page_count =0; EGwConnection *cnc; gchar *msg; CamelFolder *folder = (CamelFolder *)data; @@ -118,7 +118,7 @@ static EPopupItem popup_items[] = { }; static void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } @@ -128,8 +128,8 @@ org_gnome_junk_settings(EPlugin *ep, EMPopupTargetSelect *t) { GSList *menus = NULL; - int i = 0; - static int first = 0; + gint i = 0; + static gint first = 0; if (! g_strrstr (t->uri, "groupwise://")) return ; diff --git a/plugins/groupwise-features/junk-settings.c b/plugins/groupwise-features/junk-settings.c index 3d66a1c518..cc735feee1 100644 --- a/plugins/groupwise-features/junk-settings.c +++ b/plugins/groupwise-features/junk-settings.c @@ -35,7 +35,7 @@ struct _JunkEntry { EGwJunkEntry *entry; - int flag; + gint flag; }; typedef struct _JunkEntry JunkEntry; @@ -175,9 +175,9 @@ static void get_junk_list (JunkSettings *js) { GList *list = NULL; - char *entry; - char *msg; - int use_junk, use_block, use_pab, persistence; + gchar *entry; + gchar *msg; + gint use_junk, use_block, use_pab, persistence; if (E_IS_GW_CONNECTION (js->cnc)) { if (e_gw_connection_get_junk_settings (js->cnc, &use_junk, &use_block, &use_pab, &persistence) == E_GW_CONNECTION_STATUS_OK) { @@ -227,7 +227,7 @@ commit_changes (JunkSettings *js) GList *node = NULL; JunkEntry *junk_entry = NULL; EGwJunkEntry *entry; - int use_junk, use_pab, use_block, persistence; + gint use_junk, use_pab, use_block, persistence; for (node = js->junk_list; node; node = node->next) { @@ -301,8 +301,8 @@ disable_clicked (GtkRadioButton *button, JunkSettings *js) static void add_clicked(GtkButton *button, JunkSettings *js) { - const char *email = NULL; - const char *self_email = NULL; + const gchar *email = NULL; + const gchar *self_email = NULL; JunkEntry *new_entry = NULL; EGwJunkEntry *junk_entry = NULL; gchar *msg = NULL; @@ -372,7 +372,7 @@ static void junk_settings_construct (JunkSettings *js) { GladeXML *xml; - char *gladefile; + gchar *gladefile; gladefile = g_build_filename (EVOLUTION_GLADEDIR, "junk-settings.glade", diff --git a/plugins/groupwise-features/mail-retract.c b/plugins/groupwise-features/mail-retract.c index cf039931a5..7007ba5760 100644 --- a/plugins/groupwise-features/mail-retract.c +++ b/plugins/groupwise-features/mail-retract.c @@ -36,19 +36,19 @@ void org_gnome_retract_message (EPlugin *ep, EMPopupTargetSelect *t); -static void retract_mail_settings (EPopup *ep, EPopupItem *item, void *data) +static void retract_mail_settings (EPopup *ep, EPopupItem *item, gpointer data) { EGwConnection *cnc; CamelFolder *folder = (CamelFolder *)data; CamelStore *store = folder->parent_store; - char *id; + gchar *id; GtkWidget *confirm_dialog, *confirm_warning; - int n; + gint n; cnc = get_cnc (store); if (cnc && E_IS_GW_CONNECTION(cnc)) { - id = (char *)item->user_data; + id = (gchar *)item->user_data; confirm_dialog = gtk_dialog_new_with_buttons (_("Message Retract"), NULL, GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT, @@ -87,7 +87,7 @@ static EPopupItem popup_items[] = { { E_POPUP_ITEM, (gchar *) "20.emfv.04", (gchar *) N_("Retract Mail"), retract_mail_settings, NULL, NULL, 0, EM_POPUP_SELECT_ONE|EM_FOLDER_VIEW_SELECT_LISTONLY} }; -static void popup_free (EPopup *ep, GSList *items, void *data) +static void popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } @@ -96,8 +96,8 @@ void org_gnome_retract_message (EPlugin *ep, EMPopupTargetSelect *t) { GSList *menus = NULL; GPtrArray *uids; - int i = 0; - static int first = 0; + gint i = 0; + static gint first = 0; uids = t->uids; if (g_strrstr (t->uri, "groupwise://") && !g_ascii_strcasecmp((t->folder)->full_name, "Sent Items")) { @@ -105,7 +105,7 @@ void org_gnome_retract_message (EPlugin *ep, EMPopupTargetSelect *t) /* for translation*/ if (!first) { popup_items[1].label = _(popup_items[1].label); - popup_items[1].user_data = g_strdup((char *) g_ptr_array_index(uids, 0)); + popup_items[1].user_data = g_strdup((gchar *) g_ptr_array_index(uids, 0)); } first++; diff --git a/plugins/groupwise-features/mail-send-options.c b/plugins/groupwise-features/mail-send-options.c index 7954f9e1a4..05b3452091 100644 --- a/plugins/groupwise-features/mail-send-options.c +++ b/plugins/groupwise-features/mail-send-options.c @@ -46,7 +46,7 @@ static ESendOptionsDialog * dialog = NULL ; void org_gnome_composer_send_options (EPlugin *ep, EMEventTargetComposer *t); static time_t -add_day_to_time (time_t time, int days) +add_day_to_time (time_t time, gint days) { struct tm *tm; @@ -61,8 +61,8 @@ static void feed_input_data(ESendOptionsDialog * dialog, gint state, gpointer data) { EMsgComposer *comp; - char value [100]; - char *temp = NULL; + gchar value [100]; + gchar *temp = NULL; comp = (EMsgComposer *) data; /* we are bothered only for ok response: other cases are handled generally*/ @@ -145,7 +145,7 @@ org_gnome_composer_send_options (EPlugin *ep, EMEventTargetComposer *t) EMsgComposer *comp = (struct _EMsgComposer *)t->composer ; EComposerHeaderTable *table; EAccount *account = NULL; - char *temp = NULL; + gchar *temp = NULL; table = e_msg_composer_get_header_table (comp); account = e_composer_header_table_get_account (table); diff --git a/plugins/groupwise-features/process-meeting.c b/plugins/groupwise-features/process-meeting.c index 67123decf4..57eba9392c 100644 --- a/plugins/groupwise-features/process-meeting.c +++ b/plugins/groupwise-features/process-meeting.c @@ -44,10 +44,10 @@ ECalendarView *c_view; void org_gnome_accept(EPlugin *ep, ECalPopupTargetSelect *target); void org_gnome_retract_resend (EPlugin *ep, ECalPopupTargetSelect *target); -static void on_accept_meeting (EPopup *ep, EPopupItem *pitem, void *data); -static void on_accept_meeting_tentative (EPopup *ep, EPopupItem *pitem, void *data); -static void on_decline_meeting (EPopup *ep, EPopupItem *pitem, void *data); -static void on_resend_meeting (EPopup *ep, EPopupItem *pitem, void *data); +static void on_accept_meeting (EPopup *ep, EPopupItem *pitem, gpointer data); +static void on_accept_meeting_tentative (EPopup *ep, EPopupItem *pitem, gpointer data); +static void on_decline_meeting (EPopup *ep, EPopupItem *pitem, gpointer data); +static void on_resend_meeting (EPopup *ep, EPopupItem *pitem, gpointer data); static EPopupItem popup_items[] = { { E_POPUP_ITEM, (gchar *) "41.accept", (gchar *) N_("Accept"), on_accept_meeting, NULL, (gchar *) GTK_STOCK_APPLY, 0, E_CAL_POPUP_SELECT_NOTEDITING | E_CAL_POPUP_SELECT_MEETING | E_CAL_POPUP_SELECT_ACCEPTABLE}, @@ -56,7 +56,7 @@ static EPopupItem popup_items[] = { }; static void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); items = NULL; @@ -67,9 +67,9 @@ org_gnome_accept (EPlugin *ep, ECalPopupTargetSelect *target) { GSList *menus = NULL; GList *selected; - int i = 0; - static int first = 0; - const char *uri = NULL; + gint i = 0; + static gint first = 0; + const gchar *uri = NULL; ECalendarView *cal_view = E_CALENDAR_VIEW (target->target.widget); c_view = cal_view; @@ -135,7 +135,7 @@ receive_objects (gpointer data) } static icalproperty * -find_attendee (icalcomponent *ical_comp, const char *address) +find_attendee (icalcomponent *ical_comp, const gchar *address) { icalproperty *prop; @@ -146,8 +146,8 @@ find_attendee (icalcomponent *ical_comp, const char *address) prop != NULL; prop = icalcomponent_get_next_property (ical_comp, ICAL_ATTENDEE_PROPERTY)) { icalvalue *value; - const char *attendee; - char *text; + const gchar *attendee; + gchar *text; value = icalproperty_get_value (prop); if (!value) @@ -167,7 +167,7 @@ find_attendee (icalcomponent *ical_comp, const char *address) return prop; } static void -change_status (icalcomponent *ical_comp, const char *address, icalparameter_partstat status) +change_status (icalcomponent *ical_comp, const gchar *address, icalparameter_partstat status) { icalproperty *prop; @@ -206,7 +206,7 @@ process_meeting (ECalendarView *cal_view, icalparameter_partstat status) gboolean recurring = FALSE; GThread *thread = NULL; GError *error = NULL; - char *address = NULL; + gchar *address = NULL; e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (event->comp_data->icalcomp)); address = itip_get_comp_attendee (comp, event->comp_data->client); @@ -226,7 +226,7 @@ process_meeting (ECalendarView *cal_view, icalparameter_partstat status) if (recurring) { gint response; - const char *msg; + const gchar *msg; if (status == ICAL_PARTSTAT_ACCEPTED || status == ICAL_PARTSTAT_TENTATIVE) msg = "org.gnome.evolution.process_meeting:recurrence-accept"; @@ -236,7 +236,7 @@ process_meeting (ECalendarView *cal_view, icalparameter_partstat status) response = e_error_run (NULL, msg, NULL); if (response == GTK_RESPONSE_YES) { icalproperty *prop; - const char *uid = icalcomponent_get_uid (r_data->icalcomp); + const gchar *uid = icalcomponent_get_uid (r_data->icalcomp); prop = icalproperty_new_x ("All"); icalproperty_set_x_name (prop, "X-GW-RECUR-INSTANCES-MOD-TYPE"); @@ -263,14 +263,14 @@ process_meeting (ECalendarView *cal_view, icalparameter_partstat status) /*FIXME the data does not give us the ECalendarView object. we should remove the global c_view variable once we get it from the data*/ static void -on_accept_meeting (EPopup *ep, EPopupItem *pitem, void *data) +on_accept_meeting (EPopup *ep, EPopupItem *pitem, gpointer data) { ECalendarView *cal_view = c_view; process_meeting (cal_view, ICAL_PARTSTAT_ACCEPTED); } static void -on_accept_meeting_tentative (EPopup *ep, EPopupItem *pitem, void *data) +on_accept_meeting_tentative (EPopup *ep, EPopupItem *pitem, gpointer data) { ECalendarView *cal_view = c_view; @@ -278,7 +278,7 @@ on_accept_meeting_tentative (EPopup *ep, EPopupItem *pitem, void *data) } static void -on_decline_meeting (EPopup *ep, EPopupItem *pitem, void *data) +on_decline_meeting (EPopup *ep, EPopupItem *pitem, gpointer data) { ECalendarView *cal_view = c_view; @@ -289,8 +289,8 @@ static gboolean is_meeting_owner (ECalComponent *comp, ECal *client) { ECalComponentOrganizer org; - char *email = NULL; - const char *strip = NULL; + gchar *email = NULL; + const gchar *strip = NULL; gboolean ret_val = FALSE; if (!(e_cal_component_has_attendees (comp) && @@ -327,9 +327,9 @@ org_gnome_retract_resend (EPlugin *ep, ECalPopupTargetSelect *target) { GSList *menus = NULL; GList *selected; - int i = 0; - static int first = 0; - const char *uri = NULL; + gint i = 0; + static gint first = 0; + const gchar *uri = NULL; ECalendarView *cal_view = E_CALENDAR_VIEW (target->target.widget); ECalComponent *comp = NULL; ECalendarViewEvent *event = NULL; @@ -373,7 +373,7 @@ org_gnome_retract_resend (EPlugin *ep, ECalPopupTargetSelect *target) } static void -add_retract_data (ECalComponent *comp, const char *retract_comment, CalObjModType mod) +add_retract_data (ECalComponent *comp, const gchar *retract_comment, CalObjModType mod) { icalcomponent *icalcomp = NULL; icalproperty *icalprop = NULL; @@ -415,8 +415,8 @@ retract_object (gpointer val) ThreadData *data = val; icalcomponent *icalcomp = NULL, *mod_comp = NULL; GList *users = NULL; - char *rid = NULL; - const char *uid; + gchar *rid = NULL; + const gchar *uid; GError *error = NULL; add_retract_data (data->comp, NULL, data->mod); @@ -459,7 +459,7 @@ static void object_created_cb (CompEditor *ce, gpointer data) { GThread *thread = NULL; - int response; + gint response; GError *error = NULL; gtk_widget_hide (GTK_WIDGET (ce)); @@ -478,7 +478,7 @@ object_created_cb (CompEditor *ce, gpointer data) } static void -on_resend_meeting (EPopup *ep, EPopupItem *pitem, void *data) +on_resend_meeting (EPopup *ep, EPopupItem *pitem, gpointer data) { ECalendarView *cal_view = c_view; GList *selected; @@ -492,7 +492,7 @@ on_resend_meeting (EPopup *ep, EPopupItem *pitem, void *data) CalObjModType mod = CALOBJ_MOD_THIS; ThreadData *data = NULL; gint response; - const char *msg; + const gchar *msg; /* inserting the boolean to share the code between resend and retract */ gboolean resend = TRUE; @@ -521,7 +521,7 @@ on_resend_meeting (EPopup *ep, EPopupItem *pitem, void *data) if (resend) { guint flags = 0; - char *new_uid = NULL; + gchar *new_uid = NULL; CompEditor *ce; icalcomponent *icalcomp; diff --git a/plugins/groupwise-features/proxy-login.c b/plugins/groupwise-features/proxy-login.c index ebcf068bf0..29c6545f01 100644 --- a/plugins/groupwise-features/proxy-login.c +++ b/plugins/groupwise-features/proxy-login.c @@ -69,7 +69,7 @@ struct _proxyLoginPrivate { /*Tree View*/ GtkTreeView *tree; - char *help_section; + gchar *help_section; }; static void @@ -175,12 +175,12 @@ proxy_login_new (void) } static int -proxy_get_password (EAccount *account, char **user_name, char **password) +proxy_get_password (EAccount *account, gchar **user_name, gchar **password) { const gchar *failed_auth; - char *uri, *key, *prompt; + gchar *uri, *key, *prompt; CamelURL *url; - const char *poa_address, *use_ssl = NULL, *soap_port; + const gchar *poa_address, *use_ssl = NULL, *soap_port; url = camel_url_new (account->source->url, NULL); if (url == NULL) @@ -223,8 +223,8 @@ proxy_login_get_cnc (EAccount *account, GtkWindow *password_dlg_parrent) EGwConnection *cnc; CamelURL *url; const gchar *failed_auth; - char *uri = NULL, *key = NULL, *prompt = NULL, *password = NULL; - const char *use_ssl = NULL, *soap_port; + gchar *uri = NULL, *key = NULL, *prompt = NULL, *password = NULL; + const gchar *use_ssl = NULL, *soap_port; gboolean remember; url = camel_url_new (account->source->url, NULL); @@ -259,7 +259,7 @@ proxy_login_get_cnc (EAccount *account, GtkWindow *password_dlg_parrent) g_free (prompt); cnc = e_gw_connection_new (uri, url->user, password); if (!E_IS_GW_CONNECTION(cnc) && use_ssl && g_str_equal (use_ssl, "when-possible")) { - char *http_uri = g_strconcat ("http://", uri + 8, NULL); + gchar *http_uri = g_strconcat ("http://", uri + 8, NULL); cnc = e_gw_connection_new (http_uri, url->user, password); g_free (http_uri); } @@ -278,11 +278,11 @@ proxy_login_cb (GtkDialog *dialog, gint state) { GtkWidget *account_name_tbox; proxyLoginPrivate *priv; - char *proxy_name; + gchar *proxy_name; priv = pld->priv; account_name_tbox = glade_xml_get_widget (priv->xml, "account_name"); - proxy_name = g_strdup ((char *) gtk_entry_get_text ((GtkEntry *) account_name_tbox)); + proxy_name = g_strdup ((gchar *) gtk_entry_get_text ((GtkEntry *) account_name_tbox)); switch (state) { case GTK_RESPONSE_OK: @@ -302,18 +302,18 @@ proxy_login_cb (GtkDialog *dialog, gint state) } static void -proxy_soap_login (char *email) +proxy_soap_login (gchar *email) { EAccountList *accounts = mail_config_get_accounts(); EAccount *srcAccount; EAccount *dstAccount; EGwConnection *proxy_cnc, *cnc; CamelURL *uri = NULL, *parent = NULL ; - char *password = NULL, *user_name = NULL; - char *proxy_source_url = NULL, *parent_source_url = NULL ; - char *name; - int i; - int permissions = 0; + gchar *password = NULL, *user_name = NULL; + gchar *proxy_source_url = NULL, *parent_source_url = NULL ; + gchar *name; + gint i; + gint permissions = 0; for (i=0; email[i]!='\0' && email[i]!='@' ; i++); if (email[i]=='@') @@ -374,11 +374,11 @@ proxy_soap_login (char *email) static void -proxy_login_add_new_store (char *uri, CamelStore *store, void *user_data) +proxy_login_add_new_store (gchar *uri, CamelStore *store, gpointer user_data) { MailComponent *component = mail_component_peek (); EAccount *account = user_data; - int permissions = GPOINTER_TO_INT(g_object_get_data ((GObject *)account, "permissions")); + gint permissions = GPOINTER_TO_INT(g_object_get_data ((GObject *)account, "permissions")); if (store == NULL) return; @@ -398,7 +398,7 @@ proxy_login_tree_view_changed_cb(GtkDialog *dialog) GtkTreeIter iter; GtkWidget *account_name_tbox; GtkTreeModel *model; - char *account_mailid; + gchar *account_mailid; account_select = gtk_tree_view_get_selection (GTK_TREE_VIEW (priv->tree)); gtk_tree_selection_get_selected (account_select, &model, &iter); @@ -436,11 +436,11 @@ static void proxy_login_update_tree (void) { GtkTreeIter iter; - int i,n; + gint i,n; GdkPixbuf *broken_image = NULL; GList *proxy_list = NULL; - char *proxy_name; - char *proxy_email; + gchar *proxy_name; + gchar *proxy_email; EGwConnection *cnc; proxyLoginPrivate *priv = pld->priv; gchar *file_name = e_icon_factory_get_icon_filename ("stock_person", GTK_ICON_SIZE_DIALOG); @@ -471,12 +471,12 @@ proxy_login_update_tree (void) } void -org_gnome_proxy_account_login (EPopup *ep, EPopupItem *p, void *data) +org_gnome_proxy_account_login (EPopup *ep, EPopupItem *p, gpointer data) { - char *uri = data; + gchar *uri = data; proxyLoginPrivate *priv; EGwConnection *cnc; - char *gladefile; + gchar *gladefile; /* This pops-up the password dialog in case the User has forgot-passwords explicitly */ cnc = proxy_login_get_cnc (mail_config_get_account_by_source_url (uri), NULL); @@ -513,7 +513,7 @@ static EPopupItem popup_items[] = { }; static void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } @@ -523,7 +523,7 @@ org_gnome_create_proxy_login_option (EPlugin *ep, EMPopupTargetFolder *t) { EAccount *account; GSList *menus = NULL; - int i; + gint i; account = mail_config_get_account_by_source_url (t->uri); if (g_strrstr (t->uri,"groupwise://") && !account->parent_uid) { diff --git a/plugins/groupwise-features/proxy-login.h b/plugins/groupwise-features/proxy-login.h index 24717f8cc7..47c2b3b901 100644 --- a/plugins/groupwise-features/proxy-login.h +++ b/plugins/groupwise-features/proxy-login.h @@ -53,13 +53,13 @@ struct _proxyLoginClass { GType proxy_login_get_type (void); proxyLogin * proxy_login_new (void); static void proxy_login_cb (GtkDialog *dialog, gint state); -static void proxy_login_add_new_store (char *uri, CamelStore *store, void *user_data); +static void proxy_login_add_new_store (gchar *uri, CamelStore *store, gpointer user_data); static void proxy_login_setup_tree_view (void); -void org_gnome_proxy_account_login (EPopup *ep, EPopupItem *p, void *data); +void org_gnome_proxy_account_login (EPopup *ep, EPopupItem *p, gpointer data); proxyLogin* proxy_dialog_new (void); -static void proxy_soap_login (char *email); -char *parse_email_for_name (char *email); +static void proxy_soap_login (gchar *email); +gchar *parse_email_for_name (gchar *email); static void proxy_login_update_tree (void); static void proxy_login_tree_view_changed_cb(GtkDialog *dialog); void org_gnome_create_proxy_login_option(EPlugin *ep, EMPopupTargetFolder *t); -static int proxy_get_password (EAccount *account, char **user_name, char **password); +static gint proxy_get_password (EAccount *account, gchar **user_name, gchar **password); diff --git a/plugins/groupwise-features/proxy.c b/plugins/groupwise-features/proxy.c index 7ab0095dbf..6a18348002 100644 --- a/plugins/groupwise-features/proxy.c +++ b/plugins/groupwise-features/proxy.c @@ -62,7 +62,7 @@ static GObjectClass *parent_class = NULL; -static gboolean proxy_page_changed_cb (GtkNotebook *notebook, GtkNotebookPage *page, int num, EAccount *account); +static gboolean proxy_page_changed_cb (GtkNotebook *notebook, GtkNotebookPage *page, gint num, EAccount *account); struct _proxyDialogPrivate { /* Glade XML data for the Add/Edit Proxy dialog*/ @@ -94,7 +94,7 @@ struct _proxyDialogPrivate { GtkWidget *notifications; GtkWidget *options; GtkWidget *private; - char *help_section; + gchar *help_section; GList *proxy_list; }; @@ -254,7 +254,7 @@ proxy_dialog_new (void) static int proxy_get_permissions_from_dialog (EAccount *account) { - int permissions; + gint permissions; proxyDialogPrivate *priv; proxyDialog *prd = NULL; @@ -309,7 +309,7 @@ proxy_dialog_store_widgets_data (EAccount *account, gint32 dialog) GtkTreeModel *model; proxyHandler *new_proxy = NULL; proxyDialogPrivate *priv; - char *account_mailid; + gchar *account_mailid; proxyDialog *prd = NULL; prd = g_object_get_data ((GObject *)account, "prd"); @@ -322,7 +322,7 @@ proxy_dialog_store_widgets_data (EAccount *account, gint32 dialog) ENameSelectorEntry *name_selector_entry; EDestinationStore *destination_store; GList *destinations, *tmp; - char *name, *email; + gchar *name, *email; GList *existing_list; name_selector_entry = e_name_selector_peek_section_entry (priv->proxy_name_selector, "Add User"); destination_store = e_name_selector_entry_peek_destination_store (E_NAME_SELECTOR_ENTRY ( @@ -337,7 +337,7 @@ proxy_dialog_store_widgets_data (EAccount *account, gint32 dialog) for (; tmp != NULL; tmp = g_list_next (tmp)) { email = NULL; - email = (char *)e_destination_get_email (tmp->data); + email = (gchar *)e_destination_get_email (tmp->data); if (g_str_equal(email, "")) continue; @@ -376,12 +376,12 @@ proxy_dialog_store_widgets_data (EAccount *account, gint32 dialog) for (; tmp != NULL; tmp = g_list_next (tmp)) { name = NULL; email = NULL; - email = (char *) e_destination_get_email (tmp->data); + email = (gchar *) e_destination_get_email (tmp->data); if (g_str_equal(email, "")) continue; - name = (char *) e_destination_get_name (tmp->data); + name = (gchar *) e_destination_get_name (tmp->data); new_proxy = (proxyHandler *) g_malloc0 (sizeof (proxyHandler)); if (name) @@ -460,9 +460,9 @@ proxy_get_cnc (EAccount *account, GtkWindow *parent_window) { EGwConnection *cnc; const gchar *failed_auth; - char *uri, *key, *prompt, *password = NULL; + gchar *uri, *key, *prompt, *password = NULL; CamelURL *url; - const char *poa_address, *use_ssl, *soap_port; + const gchar *poa_address, *use_ssl, *soap_port; gboolean remember; url = camel_url_new (account->source->url, NULL); @@ -498,7 +498,7 @@ proxy_get_cnc (EAccount *account, GtkWindow *parent_window) cnc = e_gw_connection_new (uri, url->user, password); if (!E_IS_GW_CONNECTION(cnc) && use_ssl && g_str_equal (use_ssl, "when-possible")) { - char *http_uri = g_strconcat ("http://", uri + 8, NULL); + gchar *http_uri = g_strconcat ("http://", uri + 8, NULL); cnc = e_gw_connection_new (http_uri, url->user, password); g_free (http_uri); } @@ -640,8 +640,8 @@ org_gnome_proxy (EPlugin *epl, EConfigHookItemFactoryData *data) proxyDialogPrivate *priv; CamelOfflineStore *store; CamelException ex; - int pag_num; - char *gladefile; + gint pag_num; + gchar *gladefile; target_account = (EMConfigTargetAccount *)data->config->target; account = target_account->account; @@ -723,7 +723,7 @@ org_gnome_proxy (EPlugin *epl, EConfigHookItemFactoryData *data) } static gboolean -proxy_page_changed_cb (GtkNotebook *notebook, GtkNotebookPage *page, int num, EAccount *account) +proxy_page_changed_cb (GtkNotebook *notebook, GtkNotebookPage *page, gint num, EAccount *account) { proxyDialog *prd; proxyDialogPrivate *priv; @@ -823,7 +823,7 @@ proxy_edit_ok (GtkWidget *button, EAccount *account) } static proxyHandler * -proxy_get_item_from_list (EAccount *account, char *account_name) +proxy_get_item_from_list (EAccount *account, gchar *account_name) { proxyDialogPrivate *priv; proxyDialog *prd = NULL; @@ -852,7 +852,7 @@ proxy_remove_account (GtkWidget *button, EAccount *account) proxyDialogPrivate *priv; proxyHandler *deleted; GtkTreeSelection* account_select; - char *account_mailid; + gchar *account_mailid; proxyDialog *prd = NULL; prd = g_object_get_data ((GObject *)account, "prd"); @@ -906,7 +906,7 @@ proxy_add_account (GtkWidget *button, EAccount *account) ENameSelectorEntry *name_selector_entry; GtkWidget *proxy_name, *name_box; proxyDialog *prd = NULL; - char *gladefile; + gchar *gladefile; prd = g_object_get_data ((GObject *)account, "prd"); priv = prd->priv; @@ -1004,10 +1004,10 @@ proxy_edit_account (GtkWidget *button, EAccount *account) GtkTreeSelection* account_select; proxyHandler *edited; GtkButton *okButton, *proxyCancel; - char *account_mailid; + gchar *account_mailid; GtkWidget *contacts; proxyDialog *prd = NULL; - char *gladefile; + gchar *gladefile; prd = g_object_get_data ((GObject *)account, "prd"); priv = prd->priv; diff --git a/plugins/groupwise-features/proxy.h b/plugins/groupwise-features/proxy.h index c2bd933db4..ca1b651f2c 100644 --- a/plugins/groupwise-features/proxy.h +++ b/plugins/groupwise-features/proxy.h @@ -61,6 +61,6 @@ static void proxy_edit_account (GtkWidget *button, EAccount *account); void proxy_abort (GtkWidget *button, EConfigHookItemFactoryData *data); void proxy_commit (GtkWidget *button, EConfigHookItemFactoryData *data); static void proxy_setup_meta_tree_view (EAccount *account); -static proxyHandler *proxy_get_item_from_list (EAccount *account, char *account_name); +static proxyHandler *proxy_get_item_from_list (EAccount *account, gchar *account_name); static void proxy_load_edit_dialog (EAccount *account, proxyHandler *edited); void free_proxy_list (GList *proxy_list); diff --git a/plugins/groupwise-features/send-options.c b/plugins/groupwise-features/send-options.c index 33f1dd2cb4..a739571b83 100644 --- a/plugins/groupwise-features/send-options.c +++ b/plugins/groupwise-features/send-options.c @@ -56,9 +56,9 @@ get_cnc (GtkWindow *parent_window) { EGwConnection *cnc; const gchar *failed_auth; - char *uri, *key, *prompt, *password = NULL; + gchar *uri, *key, *prompt, *password = NULL; CamelURL *url; - const char *poa_address, *use_ssl, *soap_port; + const gchar *poa_address, *use_ssl, *soap_port; gboolean remember; url = camel_url_new (account->source->url, NULL); @@ -94,7 +94,7 @@ get_cnc (GtkWindow *parent_window) cnc = e_gw_connection_new (uri, url->user, password); if (!E_IS_GW_CONNECTION(cnc) && use_ssl && g_str_equal (use_ssl, "when-possible")) { - char *http_uri = g_strconcat ("http://", uri + 8, NULL); + gchar *http_uri = g_strconcat ("http://", uri + 8, NULL); cnc = e_gw_connection_new (http_uri, url->user, password); g_free (http_uri); } @@ -122,7 +122,7 @@ e_send_options_load_general_opts (ESendOptionsGeneral *gopts, EGwSendOptionsGene gopts->delay_enabled = ggopts->delay_enabled; - /* TODO convert int to timet comparing the current day */ + /* TODO convert gint to timet comparing the current day */ if (ggopts->delay_until) { gopts->delay_until = time_add_day_with_zone (temp, ggopts->delay_until, NULL); } else @@ -273,7 +273,7 @@ e_send_options_copy_general_opts (ESendOptionsGeneral *gopts, EGwSendOptionsGene ggopts->delay_enabled = gopts->delay_enabled; if (gopts->delay_until) { - int diff; + gint diff; icaltimetype temp, current; temp = icaltime_from_timet (gopts->delay_until, 0); @@ -361,14 +361,14 @@ static ESource * get_source (ESourceList *list) { GSList *p, *l; - char **temp = g_strsplit (account->source->url, ";", -1); - char *uri = temp [0]; + gchar **temp = g_strsplit (account->source->url, ";", -1); + gchar *uri = temp [0]; l = e_source_list_peek_groups (list); for (p = l; p != NULL; p = p->next) { - char *so_uri; + gchar *so_uri; GSList *r, *s; ESourceGroup *group = E_SOURCE_GROUP (p->data); @@ -398,7 +398,7 @@ add_return_value (EGwSendOptionsReturnNotify track, ESource *source, const gchar *notify) { - char *value; + gchar *value; switch (track) { case E_GW_RETURN_NOTIFY_MAIL: @@ -415,8 +415,8 @@ add_return_value (EGwSendOptionsReturnNotify track, static void put_options_in_source (ESource *source, EGwSendOptionsGeneral *gopts, EGwSendOptionsStatusTracking *sopts) { - char *value; - const char *val; + gchar *value; + const gchar *val; icaltimetype tt; CamelURL *url; diff --git a/plugins/groupwise-features/share-folder-common.c b/plugins/groupwise-features/share-folder-common.c index 74ca71fbb4..c7c315c7f0 100644 --- a/plugins/groupwise-features/share-folder-common.c +++ b/plugins/groupwise-features/share-folder-common.c @@ -62,8 +62,8 @@ struct ShareInfo { GtkWidget * org_gnome_shared_folder_factory (EPlugin *ep, EConfigHookItemFactoryData *hook_data); void org_gnome_create_option(EPlugin *ep, EMPopupTargetFolder *target); -static void create_shared_folder(EPopup *ep, EPopupItem *p, void *data); -static void popup_free (EPopup *ep, GSList *items, void *data); +static void create_shared_folder(EPopup *ep, EPopupItem *p, gpointer data); +static void popup_free (EPopup *ep, GSList *items, gpointer data); void shared_folder_commit (EPlugin *ep, EConfigTarget *tget); void shared_folder_abort (EPlugin *ep, EConfigTarget *target); @@ -126,16 +126,16 @@ struct _EMCreateFolder { /* input data */ CamelStore *store; - char *full_name; - char *parent; - char *name; + gchar *full_name; + gchar *parent; + gchar *name; /* output data */ CamelFolderInfo *fi; /* callback data */ - void (* done) (struct _EMCreateFolder *m, void *user_data); - void *user_data; + void (* done) (struct _EMCreateFolder *m, gpointer user_data); + gpointer user_data; }; static gchar * @@ -194,7 +194,7 @@ static MailMsgInfo create_folder_info = { }; static void -new_folder_created_cb (struct _EMCreateFolder *m, void *user_data) +new_folder_created_cb (struct _EMCreateFolder *m, gpointer user_data) { struct ShareInfo *ssi = (struct ShareInfo *) user_data; EMFolderSelector *emfs = ssi->emfs; @@ -208,12 +208,12 @@ new_folder_created_cb (struct _EMCreateFolder *m, void *user_data) } static int -create_folder (CamelStore *store, const char *full_name, void (* done) (struct _EMCreateFolder *m, void *user_data), void *user_data) +create_folder (CamelStore *store, const gchar *full_name, void (* done) (struct _EMCreateFolder *m, gpointer user_data), gpointer user_data) { - char *name, *namebuf = NULL; + gchar *name, *namebuf = NULL; struct _EMCreateFolder *m; - const char *parent; - int id; + const gchar *parent; + gint id; namebuf = g_strdup (full_name); if (!(name = strrchr (namebuf, '/'))) { @@ -240,11 +240,11 @@ create_folder (CamelStore *store, const char *full_name, void (* done) (struct _ } static void -users_dialog_response(GtkWidget *dialog, int response, struct ShareInfo *ssi) +users_dialog_response(GtkWidget *dialog, gint response, struct ShareInfo *ssi) { struct _EMFolderTreeModelStoreInfo *si; EMFolderSelector *emfs = ssi->emfs; - const char *uri, *path; + const gchar *uri, *path; CamelException ex; CamelStore *store; @@ -291,12 +291,12 @@ users_dialog_response(GtkWidget *dialog, int response, struct ShareInfo *ssi) } static void -new_folder_response (EMFolderSelector *emfs, int response, EMFolderTreeModel *model) +new_folder_response (EMFolderSelector *emfs, gint response, EMFolderTreeModel *model) { GtkWidget *users_dialog; GtkWidget *w; struct ShareInfo *ssi; - const char *uri; + const gchar *uri; EGwConnection *cnc; CamelException ex; CamelStore *store; @@ -341,7 +341,7 @@ static EPopupItem popup_items[] = { }; static void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } @@ -350,8 +350,8 @@ void org_gnome_create_option(EPlugin *ep, EMPopupTargetFolder *t) { GSList *menus = NULL; - int i = 0; - static int first = 0; + gint i = 0; + static gint first = 0; if (! g_strrstr (t->uri, "groupwise://")) @@ -373,13 +373,13 @@ org_gnome_create_option(EPlugin *ep, EMPopupTargetFolder *t) } static void -create_shared_folder(EPopup *ep, EPopupItem *p, void *data) +create_shared_folder(EPopup *ep, EPopupItem *p, gpointer data) { EMFolderTreeModel *model; EMFolderTree *folder_tree; GtkWidget *dialog ; - char *uri; + gchar *uri; model = mail_component_peek_tree_model (mail_component_peek ()); folder_tree = (EMFolderTree *) em_folder_tree_new_with_model (model); @@ -457,8 +457,8 @@ EGwConnection * get_cnc (CamelStore *store) { EGwConnection *cnc; - const char *uri, *property_value, *server_name, *user, *port; - char *use_ssl; + const gchar *uri, *property_value, *server_name, *user, *port; + gchar *use_ssl; CamelService *service; CamelURL *url; @@ -485,7 +485,7 @@ get_cnc (CamelStore *store) cnc = e_gw_connection_new (uri, user, service->url->passwd); if (!E_IS_GW_CONNECTION(cnc) && use_ssl && g_str_equal (use_ssl, "when-possible")) { - char *http_uri = g_strconcat ("http://", uri + 8, NULL); + gchar *http_uri = g_strconcat ("http://", uri + 8, NULL); cnc = e_gw_connection_new (http_uri, user, service->url->passwd); g_free (http_uri); } @@ -503,7 +503,7 @@ get_container_id(EGwConnection *cnc, const gchar *fname) gchar *id = NULL; gchar *name; gchar **names; - int i = 0, parts = 0; + gint i = 0, parts = 0; names = g_strsplit (fname, "/", -1); if(names){ diff --git a/plugins/groupwise-features/share-folder.c b/plugins/groupwise-features/share-folder.c index 382cf75124..2b12d4be9b 100644 --- a/plugins/groupwise-features/share-folder.c +++ b/plugins/groupwise-features/share-folder.c @@ -37,7 +37,7 @@ struct _SharedUser { EShUsers *user_node; - int flag; + gint flag; }; typedef struct _SharedUser SharedUser; @@ -321,8 +321,8 @@ not_shared_clicked (GtkRadioButton *button, ShareFolder *sf) static void add_clicked(GtkButton *button, ShareFolder *sf) { - const char *email = NULL; - const char *self_email = NULL; + const gchar *email = NULL; + const gchar *self_email = NULL; SharedUser *new_user = NULL; EShUsers *usr = NULL; gint rights = 0; @@ -513,7 +513,7 @@ notification_clicked(GtkButton *button, ShareFolder *sf) GtkButton *not_ok; GtkButton *not_cancel; GtkWidget *vbox; - char *gladefile; + gchar *gladefile; sf->window = gtk_window_new (GTK_WINDOW_TOPLEVEL); gtk_window_set_type_hint (GTK_WINDOW (sf->window), GDK_WINDOW_TYPE_HINT_DIALOG); @@ -580,7 +580,7 @@ add_right_clicked (GtkCellRenderer *renderer, gchar *arg1, ShareFolder *sf ) gboolean right = FALSE; SharedUser *usr = NULL; EShUsers *user = NULL; - char *email = NULL; + gchar *email = NULL; GtkTreePath *path = NULL; path = gtk_tree_path_new_from_string (arg1); @@ -613,7 +613,7 @@ edit_right_clicked(GtkCellRenderer *renderer, gchar *arg1, ShareFolder *sf ) gboolean right = FALSE; SharedUser *usr = NULL; EShUsers *user = NULL; - char *email = NULL; + gchar *email = NULL; GtkTreePath *path = NULL; path = gtk_tree_path_new_from_string (arg1); @@ -647,7 +647,7 @@ delete_right_clicked(GtkCellRenderer *renderer, gchar *arg1, ShareFolder *sf ) gboolean right = FALSE; SharedUser *usr = NULL; EShUsers *user = NULL; - char *email = NULL; + gchar *email = NULL; GtkTreePath *path = NULL; path = gtk_tree_path_new_from_string (arg1); @@ -682,7 +682,7 @@ share_folder_construct (ShareFolder *sf) ENameSelectorModel *name_selector_model; ENameSelectorEntry *name_selector_entry; GtkWidget *box; - char *gladefile; + gchar *gladefile; gladefile = g_build_filename (EVOLUTION_GLADEDIR, "properties.glade", diff --git a/plugins/groupwise-features/status-track.c b/plugins/groupwise-features/status-track.c index a465752c95..2569cbebd7 100644 --- a/plugins/groupwise-features/status-track.c +++ b/plugins/groupwise-features/status-track.c @@ -43,14 +43,14 @@ #include "share-folder.h" -void org_gnome_track_status (void *ep, EMPopupTargetSelect *t); +void org_gnome_track_status (gpointer ep, EMPopupTargetSelect *t); -static char * -format_date (const char * value) +static gchar * +format_date (const gchar * value) { time_t time; time_t actual_time; - char *str; + gchar *str; time = e_gw_connection_get_date_from_string (value); actual_time = camel_header_decode_date (ctime(&time), NULL); @@ -61,12 +61,12 @@ format_date (const char * value) } static void -track_status (EPopup *ep, EPopupItem *item, void *data) +track_status (EPopup *ep, EPopupItem *item, gpointer data) { EMPopupTargetSelect *t = (EMPopupTargetSelect *)data; CamelMimeMessage *msg = NULL ; const CamelInternetAddress *from ; - const char *namep, *addp ; + const gchar *namep, *addp ; GtkDialog *d ; GtkTable *table ; @@ -75,11 +75,11 @@ track_status (EPopup *ep, EPopupItem *item, void *data) GtkVBox *vbox; time_t time ; - char *time_str ; + gchar *time_str ; gchar *boldmsg; - int row = 0; + gint row = 0; EGwConnection *cnc; EGwItem *gwitem; @@ -242,17 +242,17 @@ static EPopupItem popup_items[] = { }; static void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } -void org_gnome_track_status (void *ep, EMPopupTargetSelect *t) +void org_gnome_track_status (gpointer ep, EMPopupTargetSelect *t) { GSList *menus = NULL; - int i = 0; - static int first = 0; + gint i = 0; + static gint first = 0; if (! g_strrstr (t->uri, "groupwise://") || g_ascii_strncasecmp ((t->folder)->full_name, "Sent Items", 10)) return; diff --git a/plugins/hula-account-setup/camel-hula-listener.c b/plugins/hula-account-setup/camel-hula-listener.c index 1094bec34b..966abd114f 100644 --- a/plugins/hula-account-setup/camel-hula-listener.c +++ b/plugins/hula-account-setup/camel-hula-listener.c @@ -41,9 +41,9 @@ struct _CamelHulaListenerPrivate { }; struct _HulaAccountInfo { - char *uid; - char *name; - char *source_url; + gchar *uid; + gchar *name; + gchar *source_url; }; typedef struct _HulaAccountInfo HulaAccountInfo; @@ -144,11 +144,11 @@ is_hula_caldav_account (EAccount *account) /* looks up for an existing hula account info in the hula_accounts list based on uid */ static HulaAccountInfo* -lookup_account_info (const char *key) +lookup_account_info (const gchar *key) { GList *list; HulaAccountInfo *info ; - int found = 0; + gint found = 0; if (!key) return NULL; @@ -170,7 +170,7 @@ lookup_account_info (const char *key) #define SELECTED_CALENDARS "/apps/evolution/calendar/display/selected_calendars" static void -add_esource (const char *conf_key, const char *group_name, const char *source_name, CamelURL *url) +add_esource (const gchar *conf_key, const gchar *group_name, const gchar *source_name, CamelURL *url) { ESourceList *source_list; ESourceGroup *group; @@ -178,10 +178,10 @@ add_esource (const char *conf_key, const char *group_name, const char *source_n GConfClient *client; GSList *ids, *temp ; gboolean result; - char *source_selection_key; - char *relative_uri; - const char *cal_port = "8081"; - /* const char *use_ssl = ""; */ + gchar *source_selection_key; + gchar *relative_uri; + const gchar *cal_port = "8081"; + /* const gchar *use_ssl = ""; */ /* offline_sync to come soon */ /* TODO use_ssl = camel_url_get_param (url, "use_ssl"); */ @@ -237,7 +237,7 @@ add_esource (const char *conf_key, const char *group_name, const char *source_n static void -remove_esource (const char *conf_key, const char *group_name, char* source_name, const char* relative_uri) +remove_esource (const gchar *conf_key, const gchar *group_name, gchar * source_name, const gchar * relative_uri) { ESourceList *list; GSList *groups; @@ -245,7 +245,7 @@ remove_esource (const char *conf_key, const char *group_name, char* source_name, GConfClient* client; GSList *ids; GSList *node_tobe_deleted; - char *source_selection_key; + gchar *source_selection_key; client = gconf_client_get_default(); list = e_source_list_new_for_gconf (client, conf_key); @@ -305,11 +305,11 @@ remove_esource (const char *conf_key, const char *group_name, char* source_name, /* looks for e-source with the same info as old_account_info and changes its values to the values passed in */ static void -modify_esource (const char* conf_key, HulaAccountInfo *old_account_info, const char* new_group_name, CamelURL *new_url) +modify_esource (const gchar * conf_key, HulaAccountInfo *old_account_info, const gchar * new_group_name, CamelURL *new_url) { ESourceList *list; GSList *groups; - char *old_relative_uri; + gchar *old_relative_uri; CamelURL *url; gboolean found_group; GConfClient* client; @@ -388,9 +388,9 @@ static void remove_calendar_sources (HulaAccountInfo *info) { CamelURL *url; - char *relative_uri; - const char *address; - const char *caldav_port; + gchar *relative_uri; + const gchar *address; + const gchar *caldav_port; url = camel_url_new (info->source_url, NULL); @@ -463,10 +463,10 @@ account_changed (EAccountList *account_listener, EAccount *account) { gboolean is_hula; CamelURL *old_url, *new_url; - const char *old_caldav_port, *new_caldav_port; + const gchar *old_caldav_port, *new_caldav_port; HulaAccountInfo *existing_account_info; - const char *old_use_ssl, *new_use_ssl; - const char *old_address, *new_address; + const gchar *old_use_ssl, *new_use_ssl; + const gchar *old_address, *new_address; is_hula = is_hula_account (account); if (is_hula == FALSE) diff --git a/plugins/hula-account-setup/hula-account-setup.c b/plugins/hula-account-setup/hula-account-setup.c index 84a7a4127c..29b334f115 100644 --- a/plugins/hula-account-setup/hula-account-setup.c +++ b/plugins/hula-account-setup/hula-account-setup.c @@ -27,7 +27,7 @@ static CamelHulaListener *config_listener = NULL; -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); GtkWidget* org_gnome_evolution_hula_account_setup (struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data); static void @@ -36,8 +36,8 @@ free_hula_listener ( void ) g_object_unref (config_listener); } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { if (!config_listener) { config_listener = camel_hula_listener_new (); diff --git a/plugins/imap-features/imap-headers.c b/plugins/imap-features/imap-headers.c index c33a02bdef..64f64dc16a 100644 --- a/plugins/imap-features/imap-headers.c +++ b/plugins/imap-features/imap-headers.c @@ -135,7 +135,7 @@ imap_headers_commit (EPlugin *efp, EConfigHookItemFactoryData *data) /* return true is the header is considered valid */ static gboolean -epif_header_is_valid (const char *header) +epif_header_is_valid (const gchar *header) { gint len = g_utf8_strlen (header, -1); @@ -150,7 +150,7 @@ epif_header_is_valid (const char *header) static void epif_add_sensitivity (EPImapFeaturesData *ui) { - const char *entry_contents; + const gchar *entry_contents; GtkTreeIter iter; gboolean valid; @@ -166,7 +166,7 @@ epif_add_sensitivity (EPImapFeaturesData *ui) /* check if this is a duplicate */ valid = gtk_tree_model_get_iter_first (GTK_TREE_MODEL (ui->store), &iter); while (valid) { - char *header_name; + gchar *header_name; gtk_tree_model_get (GTK_TREE_MODEL (ui->store), &iter, 0, &header_name, @@ -254,7 +254,7 @@ org_gnome_imap_headers (EPlugin *epl, EConfigHookItemFactoryData *data) GtkWidget *vbox; CamelURL *url = NULL; CamelException ex; - char *gladefile; + gchar *gladefile; GladeXML *gladexml; GtkCellRenderer *renderer; GtkTreeViewColumn *column; @@ -289,11 +289,11 @@ org_gnome_imap_headers (EPlugin *epl, EConfigHookItemFactoryData *data) gtk_tree_view_set_model (ui->custom_headers_tree, GTK_TREE_MODEL(ui->store)); if (url) { - char *custom_headers; + gchar *custom_headers; custom_headers = g_strdup(camel_url_get_param (url, "imap_custom_headers")); if (custom_headers) { - int i=0; + gint i=0; ui->custom_headers_array = g_strsplit (custom_headers, " ", -1); while (ui->custom_headers_array[i] ) { diff --git a/plugins/ipod-sync/evolution-ipod-sync.c b/plugins/ipod-sync/evolution-ipod-sync.c index 487d9f14c5..11df39777a 100644 --- a/plugins/ipod-sync/evolution-ipod-sync.c +++ b/plugins/ipod-sync/evolution-ipod-sync.c @@ -32,7 +32,7 @@ #include <gtk/gtk.h> #include <glade/glade.h> -char * mount_point = NULL; +gchar * mount_point = NULL; LibHalContext *ctx; gboolean @@ -100,7 +100,7 @@ ipod_check_status (gboolean silent) return TRUE; } -char * +gchar * ipod_get_mount (void) { return mount_point; diff --git a/plugins/ipod-sync/evolution-ipod-sync.h b/plugins/ipod-sync/evolution-ipod-sync.h index 662b16eff0..8760c43ceb 100644 --- a/plugins/ipod-sync/evolution-ipod-sync.h +++ b/plugins/ipod-sync/evolution-ipod-sync.h @@ -30,9 +30,9 @@ gboolean check_hal (void); gboolean ipod_check_status (gboolean silent); -gboolean try_umount (char *device); +gboolean try_umount (gchar *device); -char *find_ipod_mount_point (LibHalContext *ctx); -char *ipod_get_mount (void); +gchar *find_ipod_mount_point (LibHalContext *ctx); +gchar *ipod_get_mount (void); diff --git a/plugins/ipod-sync/format-handler.h b/plugins/ipod-sync/format-handler.h index 145bcb7d6d..4a9207a474 100644 --- a/plugins/ipod-sync/format-handler.h +++ b/plugins/ipod-sync/format-handler.h @@ -44,9 +44,9 @@ struct _FormatHandler gpointer data; - void (*save) (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, char *dest_uri); + void (*save) (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, gchar *dest_uri); }; FormatHandler *ical_format_handler_new (void); -GOutputStream *open_for_writing (GtkWindow *parent, const char *uri, GError **error); +GOutputStream *open_for_writing (GtkWindow *parent, const gchar *uri, GError **error); diff --git a/plugins/ipod-sync/ical-format.c b/plugins/ipod-sync/ical-format.c index 49c042f705..d8961e2520 100644 --- a/plugins/ipod-sync/ical-format.c +++ b/plugins/ipod-sync/ical-format.c @@ -37,7 +37,7 @@ #include "format-handler.h" static void -display_error_message (GtkWidget *parent, const char *message) +display_error_message (GtkWidget *parent, const gchar *message) { GtkWidget *dialog; @@ -47,7 +47,7 @@ display_error_message (GtkWidget *parent, const char *message) } static void -do_save_calendar_ical (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, char *dest_uri) +do_save_calendar_ical (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, gchar *dest_uri) { ESource *primary_source; ECal *source_client; @@ -89,7 +89,7 @@ do_save_calendar_ical (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSourc stream = open_for_writing (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (target->selector))), dest_uri, &error); if (stream && !error) { - char *ical_str = icalcomponent_as_ical_string_r (top_level); + gchar *ical_str = icalcomponent_as_ical_string_r (top_level); g_output_stream_write_all (stream, ical_str, strlen (ical_str), NULL, NULL, &error); g_output_stream_close (stream, NULL, NULL); diff --git a/plugins/ipod-sync/ipod-sync.c b/plugins/ipod-sync/ipod-sync.c index 1f589bfdc0..7615d6e7cb 100644 --- a/plugins/ipod-sync/ipod-sync.c +++ b/plugins/ipod-sync/ipod-sync.c @@ -56,7 +56,7 @@ void org_gnome_sync_addressbook (EPlugin *ep, EABPopupTargetSource *target); static void -display_error_message (GtkWidget *parent, const char *message) +display_error_message (GtkWidget *parent, const gchar *message) { GtkWidget *dialog; @@ -70,7 +70,7 @@ display_error_message (GtkWidget *parent, const char *message) It will ask for overwrite if file already exists. */ GOutputStream * -open_for_writing (GtkWindow *parent, const char *uri, GError **error) +open_for_writing (GtkWindow *parent, const gchar *uri, GError **error) { GFile *file; GFileOutputStream *fostream; @@ -125,8 +125,8 @@ destination_save_addressbook (EPlugin *ep, EABPopupTargetSource *target) gchar *uri; GOutputStream *stream; GError *error = NULL; - char *dest_uri = NULL; - char *mount = ipod_get_mount(); + gchar *dest_uri = NULL; + gchar *mount = ipod_get_mount(); primary_source = e_source_selector_peek_primary_selection (target->selector); @@ -199,8 +199,8 @@ static void destination_save_cal (EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type) { FormatHandler *handler = NULL; - char *mount = ipod_get_mount(); - char *dest_uri = NULL, *path; + gchar *mount = ipod_get_mount(); + gchar *dest_uri = NULL, *path; ESource *primary_source = e_source_selector_peek_primary_selection (target->selector); /* The available formathandlers */ diff --git a/plugins/ipod-sync/ipod.c b/plugins/ipod-sync/ipod.c index 5f399f23e6..baef16e0d5 100644 --- a/plugins/ipod-sync/ipod.c +++ b/plugins/ipod-sync/ipod.c @@ -35,8 +35,8 @@ gboolean check_hal (void) { LibHalContext *ctx; - char **devices; - int num; + gchar **devices; + gint num; DBusConnection *conn; conn = dbus_bus_get (DBUS_BUS_SYSTEM, NULL); @@ -64,9 +64,9 @@ check_hal (void) * Try to mount a given device. */ static gboolean -try_mount (char *device) +try_mount (gchar *device) { - char *argv[3]; + gchar *argv[3]; GError *err = NULL; gint exit_status; @@ -88,9 +88,9 @@ try_mount (char *device) * Try to unmount a given device. */ gboolean -try_umount (char *device) +try_umount (gchar *device) { - char *argv[3]; + gchar *argv[3]; GError *err = NULL; gint exit_status; @@ -117,11 +117,11 @@ try_umount (char *device) * database at <mount_point>/iPod_Control/iTunes/. */ static gboolean -is_ipod (char *mount_point) +is_ipod (gchar *mount_point) { gboolean ret = FALSE; - char *itunes_path; + gchar *itunes_path; itunes_path = g_build_path (G_DIR_SEPARATOR_S, mount_point, "iPod_Control", "iTunes", @@ -140,17 +140,17 @@ out: /** * Try to find a mount point for an iPod. */ -char * +gchar * find_ipod_mount_point (LibHalContext *ctx) { - char **apple_devices = NULL; - char **volumes = NULL; - char *udi, *udi2, *device, *fsusage, *mount_point = NULL; - char *retval = NULL; - int apple_count = 0; - int volume_count = 0; - int has_fs = 0; - int i, j; + gchar **apple_devices = NULL; + gchar **volumes = NULL; + gchar *udi, *udi2, *device, *fsusage, *mount_point = NULL; + gchar *retval = NULL; + gint apple_count = 0; + gint volume_count = 0; + gint has_fs = 0; + gint i, j; /* First, we look for things made by Apple. */ apple_devices = libhal_manager_find_device_string_match (ctx, diff --git a/plugins/ipod-sync/sync.c b/plugins/ipod-sync/sync.c index 8fe83d1b5a..cc2febc5e3 100644 --- a/plugins/ipod-sync/sync.c +++ b/plugins/ipod-sync/sync.c @@ -50,7 +50,7 @@ static void pulse (void) /** * Something bad happened. */ -static void error_dialog (char *title, char *error) +static void error_dialog (gchar *title, gchar *error) { GtkWidget *error_dlg = gtk_message_dialog_new (NULL, 0, GTK_MESSAGE_ERROR, GTK_BUTTONS_OK, @@ -71,7 +71,7 @@ static void error_dialog (char *title, char *error) /** * Something really bad happened. */ -static void critical_error (char *title, char *error) +static void critical_error (gchar *title, gchar *error) { error_dialog (title, error); gtk_main_quit (); @@ -79,7 +79,7 @@ static void critical_error (char *title, char *error) } static GSList * -get_source_uris_for_type (char *key) +get_source_uris_for_type (gchar *key) { ESourceList *sources; GSList *groups; @@ -124,9 +124,9 @@ free_uri_list (GSList *uris) * Note: data must be of even length. */ static void -force_little_endian (gunichar2 *data, int length) +force_little_endian (gunichar2 *data, gint length) { - int i; + gint i; /* We're big-endian? (A little tidier than before) */ @@ -151,10 +151,10 @@ force_little_endian (gunichar2 *data, int length) * display an error dialog and end the program. */ static void -write_to_ipod (GString *str, char *path, char *filename) +write_to_ipod (GString *str, gchar *path, gchar *filename) { - char *output_path; - char *output_file; + gchar *output_path; + gchar *output_file; FILE *f; guchar *utf8; gunichar2 *utf16; diff --git a/plugins/itip-formatter/itip-formatter.c b/plugins/itip-formatter/itip-formatter.c index 293c4e3fca..18aa1ea82a 100644 --- a/plugins/itip-formatter/itip-formatter.c +++ b/plugins/itip-formatter/itip-formatter.c @@ -70,7 +70,7 @@ struct _itip_puri { CamelMimeMessage *msg; CamelMimePart *part; - char *uid; + gchar *uid; GtkWidget *view; ESourceList *source_lists[E_CAL_SOURCE_TYPE_LAST]; @@ -79,7 +79,7 @@ struct _itip_puri { ECal *current_ecal; ECalSourceType type; - char *vcalendar; + gchar *vcalendar; ECalComponent *comp; icalcomponent *main_comp; icalcomponent *ical_comp; @@ -89,8 +89,8 @@ struct _itip_puri { time_t start_time; time_t end_time; - int current; - int total; + gint current; + gint total; gchar *calendar_uid; @@ -144,12 +144,12 @@ static void itip_attachment_frame(EMFormat *emf, CamelStream *stream, EMFormatPU typedef struct { struct _itip_puri *puri; - char *uid; - char *rid; + gchar *uid; + gchar *rid; - char *sexp; + gchar *sexp; - int count; + gint count; } FormatItipFindData; typedef void (* FormatItipOpenFunc) (ECal *ecal, ECalendarStatus status, gpointer data); @@ -157,7 +157,7 @@ typedef void (* FormatItipOpenFunc) (ECal *ecal, ECalendarStatus status, gpointe static gboolean check_is_instance (icalcomponent *icalcomp); static icalproperty * -find_attendee (icalcomponent *ical_comp, const char *address) +find_attendee (icalcomponent *ical_comp, const gchar *address) { icalproperty *prop; @@ -167,8 +167,8 @@ find_attendee (icalcomponent *ical_comp, const char *address) for (prop = icalcomponent_get_first_property (ical_comp, ICAL_ATTENDEE_PROPERTY); prop != NULL; prop = icalcomponent_get_next_property (ical_comp, ICAL_ATTENDEE_PROPERTY)) { - char *attendee; - char *text; + gchar *attendee; + gchar *text; attendee = icalproperty_get_value_as_string_r (prop); @@ -190,7 +190,7 @@ find_attendee (icalcomponent *ical_comp, const char *address) } static icalproperty * -find_attendee_if_sentby (icalcomponent *ical_comp, const char *address) +find_attendee_if_sentby (icalcomponent *ical_comp, const gchar *address) { icalproperty *prop; @@ -201,8 +201,8 @@ find_attendee_if_sentby (icalcomponent *ical_comp, const char *address) prop != NULL; prop = icalcomponent_get_next_property (ical_comp, ICAL_ATTENDEE_PROPERTY)) { icalparameter *param; - const char *attendee_sentby; - char *text; + const gchar *attendee_sentby; + gchar *text; param = icalproperty_get_first_parameter (prop, ICAL_SENTBY_PARAMETER); if (!param) @@ -247,7 +247,7 @@ find_to_address (struct _itip_puri *pitip, icalcomponent *ical_comp, icalparamet prop = find_attendee (ical_comp, account->id->address); if (prop) { - char *text; + gchar *text; icalparameter *param; param = icalproperty_get_first_parameter (prop, ICAL_CN_PARAMETER); @@ -303,7 +303,7 @@ find_to_address (struct _itip_puri *pitip, icalcomponent *ical_comp, icalparamet prop = find_attendee_if_sentby (ical_comp, account->id->address); if (prop) { - char *text; + gchar *text; icalparameter *param; param = icalproperty_get_first_parameter (prop, ICAL_CN_PARAMETER); @@ -342,11 +342,11 @@ find_from_address (struct _itip_puri *pitip, icalcomponent *ical_comp) { EIterator *it; icalproperty *prop; - char *organizer; + gchar *organizer; icalparameter *param; - const char *organizer_sentby; - char *organizer_clean = NULL; - char *organizer_sentby_clean = NULL; + const gchar *organizer_sentby; + gchar *organizer_clean = NULL; + gchar *organizer_sentby_clean = NULL; prop = icalcomponent_get_first_property (ical_comp, ICAL_ORGANIZER_PROPERTY); @@ -406,7 +406,7 @@ get_real_item (struct _itip_puri *pitip) ECalComponent *comp; icalcomponent *icalcomp; gboolean found = FALSE; - const char *uid; + const gchar *uid; e_cal_component_get_uid (pitip->comp, &uid); @@ -432,7 +432,7 @@ adjust_item (struct _itip_puri *pitip, ECalComponent *comp) real_comp = get_real_item (pitip); if (real_comp != NULL) { ECalComponentText text; - const char *string; + const gchar *string; GSList *l; e_cal_component_get_summary (real_comp, &text); @@ -551,9 +551,9 @@ start_calendar_server (struct _itip_puri *pitip, ESource *source, ECalSourceType } static ECal * -start_calendar_server_by_uid (struct _itip_puri *pitip, const char *uid, ECalSourceType type) +start_calendar_server_by_uid (struct _itip_puri *pitip, const gchar *uid, ECalSourceType type) { - int i; + gint i; itip_view_set_buttons_sensitive (ITIP_VIEW (pitip->view), FALSE); @@ -716,7 +716,7 @@ find_cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data) && !pitip->current_ecal) { /* Reuse already declared one or rename? */ ESource *source = NULL; - char *uid; + gchar *uid; switch (pitip->type) { case E_CAL_SOURCE_TYPE_EVENT: @@ -784,10 +784,10 @@ find_server (struct _itip_puri *pitip, ECalComponent *comp) { FormatItipFindData *fd = NULL; GSList *groups, *l, *sources_conflict = NULL, *all_sources = NULL; - const char *uid; - char *rid = NULL; + const gchar *uid; + gchar *rid = NULL; CamelURL *url; - char *uri; + gchar *uri; ESource *source = NULL, *current_source = NULL; e_cal_component_get_uid (comp, &uid); @@ -807,7 +807,7 @@ find_server (struct _itip_puri *pitip, ECalComponent *comp) sources = e_source_group_peek_sources (group); for (m = sources; m; m = m->next) { - char *source_uri = NULL; + gchar *source_uri = NULL; source = m->data; @@ -849,7 +849,7 @@ find_server (struct _itip_puri *pitip, ECalComponent *comp) source = l->data; if (!fd) { - char *start = NULL, *end = NULL; + gchar *start = NULL, *end = NULL; fd = g_new0 (FormatItipFindData, 1); fd->puri = pitip; @@ -898,7 +898,7 @@ cleanup_ecal (gpointer data) } static gboolean -change_status (icalcomponent *ical_comp, const char *address, icalparameter_partstat status) +change_status (icalcomponent *ical_comp, const gchar *address, icalparameter_partstat status) { icalproperty *prop; @@ -947,8 +947,8 @@ static void message_foreach_part (CamelMimePart *part, GSList **part_list) { CamelDataWrapper *containee; - int parts, i; - int go = TRUE; + gint parts, i; + gint go = TRUE; if (!part) return; @@ -984,7 +984,7 @@ update_item (struct _itip_puri *pitip, ItipViewResponse response) ESource *source; GError *error = NULL; gboolean result = TRUE; - char *str; + gchar *str; /* Set X-MICROSOFT-CDO-REPLYTIME to record the time at which * the user accepted/declined the request. (Outlook ignores @@ -1037,7 +1037,7 @@ update_item (struct _itip_puri *pitip, ItipViewResponse response) alarms = e_cal_component_get_alarm_uids (real_comp); for (l = alarms; l; l = l->next) { - alarm = e_cal_component_get_alarm (real_comp, (const char *)l->data); + alarm = e_cal_component_get_alarm (real_comp, (const gchar *)l->data); if (alarm) { ECalComponentAlarm *aclone = e_cal_component_alarm_clone (alarm); @@ -1065,7 +1065,7 @@ update_item (struct _itip_puri *pitip, ItipViewResponse response) for (l = attachments; l; l = l->next) { GSList *parts = NULL, *m; - char *uri, *new_uri; + gchar *uri, *new_uri; CamelMimePart *part; uri = l->data; @@ -1152,7 +1152,7 @@ update_item (struct _itip_puri *pitip, ItipViewResponse response) /* TODO These operations should be available in e-cal-component.c */ static void -set_attendee (ECalComponent *comp, const char *address) +set_attendee (ECalComponent *comp, const gchar *address) { icalproperty *prop; icalcomponent *icalcomp; @@ -1163,7 +1163,7 @@ set_attendee (ECalComponent *comp, const char *address) for (prop = icalcomponent_get_first_property (icalcomp, ICAL_ATTENDEE_PROPERTY); prop; prop = icalcomponent_get_next_property (icalcomp, ICAL_ATTENDEE_PROPERTY)) { - const char *attendee = icalproperty_get_attendee (prop); + const gchar *attendee = icalproperty_get_attendee (prop); if (!(g_str_equal (itip_strip_mailto (attendee), address))) icalcomponent_remove_property (icalcomp, prop); @@ -1173,9 +1173,9 @@ set_attendee (ECalComponent *comp, const char *address) if (!found) { icalparameter *param; - char *temp = g_strdup_printf ("MAILTO:%s", address); + gchar *temp = g_strdup_printf ("MAILTO:%s", address); - prop = icalproperty_new_attendee ((const char *) temp); + prop = icalproperty_new_attendee ((const gchar *) temp); icalcomponent_add_property (icalcomp, prop); param = icalparameter_new_partstat (ICAL_PARTSTAT_NEEDSACTION); @@ -1196,7 +1196,7 @@ set_attendee (ECalComponent *comp, const char *address) } static gboolean -send_comp_to_attendee (ECalComponentItipMethod method, ECalComponent *comp, const char *user, ECal *client, const char *comment) +send_comp_to_attendee (ECalComponentItipMethod method, ECalComponent *comp, const gchar *user, ECal *client, const gchar *comment) { gboolean status; ECalComponent *send_comp = e_cal_component_clone (comp); @@ -1225,10 +1225,10 @@ send_comp_to_attendee (ECalComponentItipMethod method, ECalComponent *comp, cons } static void -remove_delegate (struct _itip_puri *pitip, const char *delegate, const char *delegator, ECalComponent *comp) +remove_delegate (struct _itip_puri *pitip, const gchar *delegate, const gchar *delegator, ECalComponent *comp) { gboolean status; - char *comment = g_strdup_printf (_("Organizer has removed the delegate %s "), itip_strip_mailto (delegate)); + gchar *comment = g_strdup_printf (_("Organizer has removed the delegate %s "), itip_strip_mailto (delegate)); /* send cancellation notice to delegate */ status = send_comp_to_attendee (E_CAL_COMPONENT_METHOD_CANCEL, pitip->comp, delegate, pitip->current_ecal, comment); @@ -1251,7 +1251,7 @@ update_x (ECalComponent *pitip_comp, ECalComponent *comp) icalproperty *prop = icalcomponent_get_first_property (itip_icalcomp, ICAL_X_PROPERTY); while (prop) { - const char *name = icalproperty_get_x_name (prop); + const gchar *name = icalproperty_get_x_name (prop); if (!g_ascii_strcasecmp (name, "X-EVOLUTION-IS-REPLY")) { icalproperty *new_prop = icalproperty_new_x (icalproperty_get_x (prop)); icalproperty_set_x_name (new_prop, "X-EVOLUTION-IS-REPLY"); @@ -1268,9 +1268,9 @@ update_attendee_status (struct _itip_puri *pitip) { ECalComponent *comp = NULL; icalcomponent *icalcomp = NULL, *org_icalcomp; - const char *uid; - char *rid = NULL; - const char *delegate; + const gchar *uid; + gchar *rid = NULL; + const gchar *delegate; GError *error = NULL; /* Obtain our version */ @@ -1455,10 +1455,10 @@ get_next (icalcompiter *iter) } static void -set_itip_error (struct _itip_puri *pitip, GtkContainer *container, const char *primary, const char *secondary) +set_itip_error (struct _itip_puri *pitip, GtkContainer *container, const gchar *primary, const gchar *secondary) { GtkWidget *vbox, *label; - char *message; + gchar *message; vbox = gtk_vbox_new (FALSE, 12); gtk_widget_show (vbox); @@ -1489,7 +1489,7 @@ extract_itip_data (struct _itip_puri *pitip, GtkContainer *container, gboolean * icalcomponent *alarm_comp; icalcompiter alarm_iter; ECalComponent *comp; - char *my_address; + gchar *my_address; if (!pitip->vcalendar) { @@ -1610,7 +1610,7 @@ extract_itip_data (struct _itip_puri *pitip, GtkContainer *container, gboolean * prop = find_attendee_if_sentby (pitip->ical_comp, my_address); if (prop) { icalparameter *param; - const char * delfrom; + const gchar * delfrom; if ((param = icalproperty_get_first_parameter (prop, ICAL_DELEGATEDFROM_PARAMETER))) { delfrom = icalparameter_get_delegatedfrom (param); @@ -1623,7 +1623,7 @@ extract_itip_data (struct _itip_puri *pitip, GtkContainer *container, gboolean * /* Determine any delegate sections */ prop = icalcomponent_get_first_property (pitip->ical_comp, ICAL_X_PROPERTY); while (prop) { - const char *x_name, *x_val; + const gchar *x_name, *x_val; x_name = icalproperty_get_x_name (prop); x_val = icalproperty_get_x (prop); @@ -1675,7 +1675,7 @@ extract_itip_data (struct _itip_puri *pitip, GtkContainer *container, gboolean * /* Add default reminder if the config says so */ if (calendar_config_get_use_default_reminder ()) { ECalComponentAlarm *acomp; - int interval; + gint interval; CalUnits units; ECalComponentAlarmTrigger trigger; @@ -1720,10 +1720,10 @@ extract_itip_data (struct _itip_puri *pitip, GtkContainer *container, gboolean * struct _opencal_msg { MailMsg base; - char *command; /* command line to run */ + gchar *command; /* command line to run */ }; -static char * +static gchar * open_calendar__desc (struct _opencal_msg *m, gint complete) { return g_strdup (_("Opening calendar")); @@ -1757,7 +1757,7 @@ idle_open_cb (gpointer data) { struct _itip_puri *pitip = data; struct _opencal_msg *m; - char *start, *end; + gchar *start, *end; start = isodate_from_time_t (pitip->start_time); end = isodate_from_time_t (pitip->end_time); @@ -1869,7 +1869,7 @@ view_response_cb (GtkWidget *widget, ItipViewResponse response, gpointer data) /* FIXME Remove this and handle this at the groupwise mail provider */ if (delete_invitation_from_cache) { CamelFolderChangeInfo *changes = NULL; - const char *tag = NULL; + const gchar *tag = NULL; CamelMessageInfo *mi; mi = camel_folder_summary_uid (pitip->folder->summary, pitip->uid); if (mi) { @@ -1881,7 +1881,7 @@ view_response_cb (GtkWidget *widget, ItipViewResponse response, gpointer data) tag = camel_message_info_user_tag (mi, "recurrence-key"); camel_message_info_free (mi); if (tag) { - int i = 0, count; + gint i = 0, count; GSList *list = NULL; count = camel_folder_summary_count (pitip->folder->summary); @@ -1891,8 +1891,8 @@ view_response_cb (GtkWidget *widget, ItipViewResponse response, gpointer data) continue; camel_message_info_ref (mi); if ( camel_message_info_user_tag (mi, "recurrence-key") && g_str_equal (camel_message_info_user_tag (mi, "recurrence-key"), tag)) { - camel_folder_summary_remove_uid_fast (pitip->folder->summary, (char *)(mi->uid)); - camel_folder_change_info_remove_uid (changes, (char *) mi->uid); + camel_folder_summary_remove_uid_fast (pitip->folder->summary, (gchar *)(mi->uid)); + camel_folder_change_info_remove_uid (changes, (gchar *) mi->uid); list = g_slist_prepend (list, (gpointer) mi->uid); /* step back once to have the right index */ @@ -1924,7 +1924,7 @@ view_response_cb (GtkWidget *widget, ItipViewResponse response, gpointer data) ECalComponent *comp = NULL; icalcomponent *ical_comp; icalvalue *value; - const char *attendee, *comment; + const gchar *attendee, *comment; GSList *l, *list = NULL; gboolean found; @@ -1944,7 +1944,7 @@ view_response_cb (GtkWidget *widget, ItipViewResponse response, gpointer data) prop != NULL; prop = icalcomponent_get_next_property (ical_comp, ICAL_ATTENDEE_PROPERTY)) { - char *text; + gchar *text; value = icalproperty_get_value (prop); if (!value) @@ -2003,7 +2003,7 @@ check_is_instance (icalcomponent *icalcomp) icalprop = icalcomponent_get_first_property (icalcomp, ICAL_X_PROPERTY); while (icalprop) { - const char *x_name; + const gchar *x_name; x_name = icalproperty_get_x_name (icalprop); if (!strcmp (x_name, "X-GW-RECURRENCE-KEY")) { @@ -2047,8 +2047,8 @@ format_itip_object (EMFormatHTML *efh, GtkHTMLEmbedded *eb, EMFormatHTMLPObject GString *gstring = NULL; GSList *list, *l; icalcomponent *icalcomp; - const char *string, *org; - int i; + const gchar *string, *org; + gint i; gboolean response_enabled; gboolean have_alarms = FALSE; @@ -2351,7 +2351,7 @@ static void puri_free (EMFormatPURI *puri) { struct _itip_puri *pitip = (struct _itip_puri*) puri; - int i; + gint i; for (i = 0; i < E_CAL_SOURCE_TYPE_LAST; i++) { if (pitip->source_lists[i]) @@ -2407,7 +2407,7 @@ format_itip (EPlugin *ep, EMFormatHookTarget *target) { EMFormatHTMLPObject *pobj; GConfClient *gconf; - char *classid; + gchar *classid; struct _itip_puri *puri; CamelDataWrapper *content; CamelStream *mem; @@ -2442,7 +2442,7 @@ format_itip (EPlugin *ep, EMFormatHookTarget *target) if (((CamelStreamMem *) mem)->buffer->len == 0) puri->vcalendar = NULL; else - puri->vcalendar = g_strndup ((char *)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len); + puri->vcalendar = g_strndup ((gchar *)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len); camel_object_unref (mem); @@ -2471,7 +2471,7 @@ initialize_selection (ESourceSelector *selector, ESourceList *source_list) GSList *sources; for (sources = e_source_group_peek_sources (group); sources; sources = sources->next) { ESource *source = E_SOURCE (sources->data); - const char *completion = e_source_get_property (source, "conflict"); + const gchar *completion = e_source_get_property (source, "conflict"); if (completion && !g_ascii_strcasecmp (completion, "true")) e_source_selector_select_source (selector, source); } diff --git a/plugins/itip-formatter/itip-view.c b/plugins/itip-formatter/itip-view.c index 30dbe135cc..c2fe0e163a 100644 --- a/plugins/itip-formatter/itip-view.c +++ b/plugins/itip-formatter/itip-view.c @@ -50,7 +50,7 @@ G_DEFINE_TYPE (ItipView, itip_view, GTK_TYPE_HBOX) typedef struct { ItipViewInfoItemType type; - char *message; + gchar *message; guint id; } ItipViewInfoItem; @@ -60,27 +60,27 @@ struct _ItipViewPrivate { ECalSourceType type; GtkWidget *sender_label; - char *organizer; - char *organizer_sentby; - char *delegator; - char *attendee; - char *attendee_sentby; - char *proxy; + gchar *organizer; + gchar *organizer_sentby; + gchar *delegator; + gchar *attendee; + gchar *attendee_sentby; + gchar *proxy; GtkWidget *summary_label; - char *summary; + gchar *summary; GtkWidget *location_header; GtkWidget *location_label; - char *location; + gchar *location; GtkWidget *status_header; GtkWidget *status_label; - char *status; + gchar *status; GtkWidget *comment_header; GtkWidget *comment_label; - char *comment; + gchar *comment; GtkWidget *start_header; GtkWidget *start_label; @@ -99,7 +99,7 @@ struct _ItipViewPrivate { guint next_info_item_id; GtkWidget *description_label; - char *description; + gchar *description; GtkWidget *selector_box; GtkWidget *escb; @@ -148,7 +148,7 @@ format_date_and_time_x (struct tm *date_tm, char *buffer, int buffer_size) { - char *format; + gchar *format; struct tm tomorrow_tm, week_tm; /* Calculate a normalized "tomorrow" */ @@ -337,9 +337,9 @@ static void set_calendar_sender_text (ItipView *view) { ItipViewPrivate *priv; - const char *organizer, *attendee; - char *sender = NULL; - char *on_behalf_of = NULL; + const gchar *organizer, *attendee; + gchar *sender = NULL; + gchar *on_behalf_of = NULL; priv = view->priv; @@ -425,9 +425,9 @@ static void set_tasklist_sender_text (ItipView *view) { ItipViewPrivate *priv; - const char *organizer, *attendee; - char *sender = NULL; - char *on_behalf_of = NULL; + const gchar *organizer, *attendee; + gchar *sender = NULL; + gchar *on_behalf_of = NULL; priv = view->priv; @@ -513,9 +513,9 @@ static void set_journal_sender_text (ItipView *view) { ItipViewPrivate *priv; - const char *organizer, *attendee; - char *sender = NULL; - char *on_behalf_of = NULL; + const gchar *organizer, *attendee; + gchar *sender = NULL; + gchar *on_behalf_of = NULL; priv = view->priv; @@ -589,7 +589,7 @@ static void set_summary_text (ItipView *view) { ItipViewPrivate *priv; - char *summary = NULL; + gchar *summary = NULL; priv = view->priv; @@ -656,7 +656,7 @@ static void set_start_text (ItipView *view) { ItipViewPrivate *priv; - char buffer[256]; + gchar buffer[256]; time_t now; struct tm *now_tm; @@ -680,7 +680,7 @@ static void set_end_text (ItipView *view) { ItipViewPrivate *priv; - char buffer[256]; + gchar buffer[256]; time_t now; struct tm *now_tm; @@ -1242,7 +1242,7 @@ itip_view_get_item_type (ItipView *view) /* ensures the returned text will be valid UTF-8 text, thus gtk functions expecting only valid UTF-8 texts will not crash. Returned pointer should be freed with g_free. */ static gchar * -ensure_utf8 (const char *text) +ensure_utf8 (const gchar *text) { gchar *res = g_strdup (text), *p; @@ -1259,7 +1259,7 @@ ensure_utf8 (const char *text) } void -itip_view_set_organizer (ItipView *view, const char *organizer) +itip_view_set_organizer (ItipView *view, const gchar *organizer) { ItipViewPrivate *priv; @@ -1276,7 +1276,7 @@ itip_view_set_organizer (ItipView *view, const char *organizer) set_sender_text (view); } -const char * +const gchar * itip_view_get_organizer (ItipView *view) { ItipViewPrivate *priv; @@ -1290,7 +1290,7 @@ itip_view_get_organizer (ItipView *view) } void -itip_view_set_organizer_sentby (ItipView *view, const char *sentby) +itip_view_set_organizer_sentby (ItipView *view, const gchar *sentby) { ItipViewPrivate *priv; @@ -1307,7 +1307,7 @@ itip_view_set_organizer_sentby (ItipView *view, const char *sentby) set_sender_text (view); } -const char * +const gchar * itip_view_get_organizer_sentby (ItipView *view) { ItipViewPrivate *priv; @@ -1321,7 +1321,7 @@ itip_view_get_organizer_sentby (ItipView *view) } void -itip_view_set_attendee (ItipView *view, const char *attendee) +itip_view_set_attendee (ItipView *view, const gchar *attendee) { ItipViewPrivate *priv; @@ -1338,7 +1338,7 @@ itip_view_set_attendee (ItipView *view, const char *attendee) set_sender_text (view); } -const char * +const gchar * itip_view_get_attendee (ItipView *view) { ItipViewPrivate *priv; @@ -1352,7 +1352,7 @@ itip_view_get_attendee (ItipView *view) } void -itip_view_set_attendee_sentby (ItipView *view, const char *sentby) +itip_view_set_attendee_sentby (ItipView *view, const gchar *sentby) { ItipViewPrivate *priv; @@ -1369,7 +1369,7 @@ itip_view_set_attendee_sentby (ItipView *view, const char *sentby) set_sender_text (view); } -const char * +const gchar * itip_view_get_attendee_sentby (ItipView *view) { ItipViewPrivate *priv; @@ -1383,7 +1383,7 @@ itip_view_get_attendee_sentby (ItipView *view) } void -itip_view_set_proxy (ItipView *view, const char *proxy) +itip_view_set_proxy (ItipView *view, const gchar *proxy) { ItipViewPrivate *priv; @@ -1400,7 +1400,7 @@ itip_view_set_proxy (ItipView *view, const char *proxy) set_sender_text (view); } -const char * +const gchar * itip_view_get_proxy (ItipView *view) { ItipViewPrivate *priv; @@ -1414,7 +1414,7 @@ itip_view_get_proxy (ItipView *view) } void -itip_view_set_delegator (ItipView *view, const char *delegator) +itip_view_set_delegator (ItipView *view, const gchar *delegator) { ItipViewPrivate *priv; @@ -1431,7 +1431,7 @@ itip_view_set_delegator (ItipView *view, const char *delegator) set_sender_text (view); } -const char * +const gchar * itip_view_get_delegator (ItipView *view) { ItipViewPrivate *priv; @@ -1445,7 +1445,7 @@ itip_view_get_delegator (ItipView *view) } void -itip_view_set_summary (ItipView *view, const char *summary) +itip_view_set_summary (ItipView *view, const gchar *summary) { ItipViewPrivate *priv; @@ -1462,7 +1462,7 @@ itip_view_set_summary (ItipView *view, const char *summary) set_summary_text (view); } -const char * +const gchar * itip_view_get_summary (ItipView *view) { ItipViewPrivate *priv; @@ -1476,7 +1476,7 @@ itip_view_get_summary (ItipView *view) } void -itip_view_set_location (ItipView *view, const char *location) +itip_view_set_location (ItipView *view, const gchar *location) { ItipViewPrivate *priv; @@ -1493,7 +1493,7 @@ itip_view_set_location (ItipView *view, const char *location) set_location_text (view); } -const char * +const gchar * itip_view_get_location (ItipView *view) { ItipViewPrivate *priv; @@ -1507,7 +1507,7 @@ itip_view_get_location (ItipView *view) } void -itip_view_set_status (ItipView *view, const char *status) +itip_view_set_status (ItipView *view, const gchar *status) { ItipViewPrivate *priv; @@ -1524,7 +1524,7 @@ itip_view_set_status (ItipView *view, const char *status) set_status_text (view); } -const char * +const gchar * itip_view_get_status (ItipView *view) { ItipViewPrivate *priv; @@ -1538,7 +1538,7 @@ itip_view_get_status (ItipView *view) } void -itip_view_set_comment (ItipView *view, const char *comment) +itip_view_set_comment (ItipView *view, const gchar *comment) { ItipViewPrivate *priv; @@ -1555,7 +1555,7 @@ itip_view_set_comment (ItipView *view, const char *comment) set_comment_text (view); } -const char * +const gchar * itip_view_get_comment (ItipView *view) { ItipViewPrivate *priv; @@ -1570,7 +1570,7 @@ itip_view_get_comment (ItipView *view) void -itip_view_set_description (ItipView *view, const char *description) +itip_view_set_description (ItipView *view, const gchar *description) { ItipViewPrivate *priv; @@ -1587,7 +1587,7 @@ itip_view_set_description (ItipView *view, const char *description) set_description_text (view); } -const char * +const gchar * itip_view_get_description (ItipView *view) { ItipViewPrivate *priv; @@ -1674,7 +1674,7 @@ itip_view_get_end (ItipView *view) } guint -itip_view_add_upper_info_item (ItipView *view, ItipViewInfoItemType type, const char *message) +itip_view_add_upper_info_item (ItipView *view, ItipViewInfoItemType type, const gchar *message) { ItipViewPrivate *priv; ItipViewInfoItem *item; @@ -1698,10 +1698,10 @@ itip_view_add_upper_info_item (ItipView *view, ItipViewInfoItemType type, const } guint -itip_view_add_upper_info_item_printf (ItipView *view, ItipViewInfoItemType type, const char *format, ...) +itip_view_add_upper_info_item_printf (ItipView *view, ItipViewInfoItemType type, const gchar *format, ...) { va_list args; - char *message; + gchar *message; guint id; g_return_val_if_fail (view != NULL, 0); @@ -1769,7 +1769,7 @@ itip_view_clear_upper_info_items (ItipView *view) } guint -itip_view_add_lower_info_item (ItipView *view, ItipViewInfoItemType type, const char *message) +itip_view_add_lower_info_item (ItipView *view, ItipViewInfoItemType type, const gchar *message) { ItipViewPrivate *priv; ItipViewInfoItem *item; @@ -1793,10 +1793,10 @@ itip_view_add_lower_info_item (ItipView *view, ItipViewInfoItemType type, const } guint -itip_view_add_lower_info_item_printf (ItipView *view, ItipViewInfoItemType type, const char *format, ...) +itip_view_add_lower_info_item_printf (ItipView *view, ItipViewInfoItemType type, const gchar *format, ...) { va_list args; - char *message; + gchar *message; guint id; g_return_val_if_fail (view != NULL, 0); @@ -2084,7 +2084,7 @@ itip_view_get_show_update (ItipView *view) } void -itip_view_set_rsvp_comment (ItipView *view, const char *comment) +itip_view_set_rsvp_comment (ItipView *view, const gchar *comment) { ItipViewPrivate *priv; @@ -2096,7 +2096,7 @@ itip_view_set_rsvp_comment (ItipView *view, const char *comment) gtk_entry_set_text (GTK_ENTRY (priv->rsvp_comment_entry), comment); } -const char * +const gchar * itip_view_get_rsvp_comment (ItipView *view) { ItipViewPrivate *priv; diff --git a/plugins/itip-formatter/itip-view.h b/plugins/itip-formatter/itip-view.h index 88d01204fb..2b834b01c8 100644 --- a/plugins/itip-formatter/itip-view.h +++ b/plugins/itip-formatter/itip-view.h @@ -87,7 +87,7 @@ struct _ItipViewClass { GtkHBoxClass parent_class; void (* source_selected) (ItipView *view, ESource *selected_source); - void (* response) (ItipView *view, int response); + void (* response) (ItipView *view, gint response); }; GType itip_view_get_type (void); @@ -99,38 +99,38 @@ ItipViewMode itip_view_get_mode (ItipView *view); void itip_view_set_item_type (ItipView *view, ECalSourceType type); ECalSourceType itip_view_get_item_type (ItipView *view); -void itip_view_set_organizer (ItipView *view, const char *organizer); -const char *itip_view_get_organizer (ItipView *view); +void itip_view_set_organizer (ItipView *view, const gchar *organizer); +const gchar *itip_view_get_organizer (ItipView *view); -void itip_view_set_organizer_sentby (ItipView *view, const char *sentby); -const char *itip_view_get_organizer_sentby (ItipView *view); +void itip_view_set_organizer_sentby (ItipView *view, const gchar *sentby); +const gchar *itip_view_get_organizer_sentby (ItipView *view); -void itip_view_set_attendee (ItipView *view, const char *attendee); -const char *itip_view_get_attendee (ItipView *view); +void itip_view_set_attendee (ItipView *view, const gchar *attendee); +const gchar *itip_view_get_attendee (ItipView *view); -void itip_view_set_attendee_sentby (ItipView *view, const char *sentby); -const char *itip_view_get_attendee_sentby (ItipView *view); +void itip_view_set_attendee_sentby (ItipView *view, const gchar *sentby); +const gchar *itip_view_get_attendee_sentby (ItipView *view); -void itip_view_set_delegator (ItipView *view, const char *delegator); -const char *itip_view_get_delegator (ItipView *view); +void itip_view_set_delegator (ItipView *view, const gchar *delegator); +const gchar *itip_view_get_delegator (ItipView *view); -void itip_view_set_proxy (ItipView *view, const char *proxy); -const char *itip_view_get_proxy (ItipView *view); +void itip_view_set_proxy (ItipView *view, const gchar *proxy); +const gchar *itip_view_get_proxy (ItipView *view); -void itip_view_set_summary (ItipView *view, const char *summary); -const char *itip_view_get_summary (ItipView *view); +void itip_view_set_summary (ItipView *view, const gchar *summary); +const gchar *itip_view_get_summary (ItipView *view); -void itip_view_set_location (ItipView *view, const char *location); -const char *itip_view_get_location (ItipView *view); +void itip_view_set_location (ItipView *view, const gchar *location); +const gchar *itip_view_get_location (ItipView *view); -void itip_view_set_status (ItipView *view, const char *status); -const char *itip_view_get_status (ItipView *view); +void itip_view_set_status (ItipView *view, const gchar *status); +const gchar *itip_view_get_status (ItipView *view); -void itip_view_set_comment (ItipView *view, const char *comment); -const char *itip_view_get_comment (ItipView *view); +void itip_view_set_comment (ItipView *view, const gchar *comment); +const gchar *itip_view_get_comment (ItipView *view); -void itip_view_set_description (ItipView *view, const char *description); -const char *itip_view_get_description (ItipView *view); +void itip_view_set_description (ItipView *view, const gchar *description); +const gchar *itip_view_get_description (ItipView *view); void itip_view_set_start (ItipView *view, struct tm *start); const struct tm *itip_view_get_start (ItipView *view); @@ -138,13 +138,13 @@ const struct tm *itip_view_get_start (ItipView *view); void itip_view_set_end (ItipView *view, struct tm *end); const struct tm *itip_view_get_end (ItipView *view); -guint itip_view_add_upper_info_item (ItipView *view, ItipViewInfoItemType type, const char *message); -guint itip_view_add_upper_info_item_printf (ItipView *view, ItipViewInfoItemType, const char *format, ...) G_GNUC_PRINTF (3, 4); +guint itip_view_add_upper_info_item (ItipView *view, ItipViewInfoItemType type, const gchar *message); +guint itip_view_add_upper_info_item_printf (ItipView *view, ItipViewInfoItemType, const gchar *format, ...) G_GNUC_PRINTF (3, 4); void itip_view_remove_upper_info_item (ItipView *view, guint id); void itip_view_clear_upper_info_items (ItipView *view); -guint itip_view_add_lower_info_item (ItipView *view, ItipViewInfoItemType type, const char *message); -guint itip_view_add_lower_info_item_printf (ItipView *view, ItipViewInfoItemType type, const char *format, ...) G_GNUC_PRINTF (3, 4); +guint itip_view_add_lower_info_item (ItipView *view, ItipViewInfoItemType type, const gchar *message); +guint itip_view_add_lower_info_item_printf (ItipView *view, ItipViewInfoItemType type, const gchar *format, ...) G_GNUC_PRINTF (3, 4); void itip_view_remove_lower_info_item (ItipView *view, guint id); void itip_view_clear_lower_info_items (ItipView *view); @@ -166,8 +166,8 @@ gboolean itip_view_get_update (ItipView *view); void itip_view_set_show_update (ItipView *view, gboolean update); gboolean itip_view_get_show_update (ItipView *view); -void itip_view_set_rsvp_comment (ItipView *view, const char *comment); -const char *itip_view_get_rsvp_comment (ItipView *view); +void itip_view_set_rsvp_comment (ItipView *view, const gchar *comment); +const gchar *itip_view_get_rsvp_comment (ItipView *view); void itip_view_set_buttons_sensitive (ItipView *view, gboolean sensitive); gboolean itip_view_get_buttons_sensitive (ItipView *view); diff --git a/plugins/mail-account-disable/mail-account-disable.c b/plugins/mail-account-disable/mail-account-disable.c index d03e97d0f8..aee3043682 100644 --- a/plugins/mail-account-disable/mail-account-disable.c +++ b/plugins/mail-account-disable/mail-account-disable.c @@ -38,7 +38,7 @@ #define ACCOUNT_DISABLE 0 #define PROXY_LOGOUT 1 -void mail_account_disable (EPopup *ep, EPopupItem *p, void *data); +void mail_account_disable (EPopup *ep, EPopupItem *p, gpointer data); void org_gnome_create_mail_account_disable (EPlugin *ep, EMPopupTargetFolder *t); static EPopupItem popup_items[] = { @@ -47,13 +47,13 @@ static EPopupItem popup_items[] = { }; static void -popup_free (EPopup *ep, GSList *items, void *data) +popup_free (EPopup *ep, GSList *items, gpointer data) { g_slist_free (items); } void -mail_account_disable (EPopup *ep, EPopupItem *p, void *data) +mail_account_disable (EPopup *ep, EPopupItem *p, gpointer data) { MailComponent *component; EAccount *account = data; diff --git a/plugins/mail-notification/mail-notification.c b/plugins/mail-notification/mail-notification.c index 466648d80f..d7c0f8a3dd 100644 --- a/plugins/mail-notification/mail-notification.c +++ b/plugins/mail-notification/mail-notification.c @@ -66,7 +66,7 @@ static GStaticMutex mlock = G_STATIC_MUTEX_INIT; * b) void read_notify_... (EMEventTargetMessage *t) * it is called when read_notify message is sent by Evolution * - * c) void enable_... (int enable) + * c) void enable_... (gint enable) * when plugin itself or the part is enabled/disabled * * d) GtkWidget *get_config_widget_...(void) @@ -127,7 +127,7 @@ static DBusConnection *bus = NULL; static gboolean init_dbus (void); static void -send_dbus_message (const char *name, const char *data, guint new) +send_dbus_message (const gchar *name, const gchar *data, guint new) { DBusMessage *message; @@ -145,7 +145,7 @@ send_dbus_message (const char *name, const char *data, guint new) DBUS_TYPE_INVALID); if (new) { - char * display_name = em_utils_folder_name_from_uri (data); + gchar * display_name = em_utils_folder_name_from_uri (data); dbus_message_append_args (message, #if FOUND_DBUS_VERSION >= 310 DBUS_TYPE_STRING, &display_name, DBUS_TYPE_UINT32, &new, @@ -174,7 +174,7 @@ reinit_dbus (gpointer user_data) } static DBusHandlerResult -filter_function (DBusConnection *connection, DBusMessage *message, void *user_data) +filter_function (DBusConnection *connection, DBusMessage *message, gpointer user_data) { if (dbus_message_is_signal (message, DBUS_INTERFACE_LOCAL, "Disconnected") && strcmp (dbus_message_get_path (message), DBUS_PATH_LOCAL) == 0) { @@ -237,7 +237,7 @@ read_notify_dbus (EMEventTargetMessage *t) } static void -enable_dbus (int enable) +enable_dbus (gint enable) { if (enable) { /* we ignore errors here */ @@ -273,7 +273,7 @@ get_config_widget_dbus (void) static GtkStatusIcon *status_icon = NULL; static guint blink_timeout_id = 0; -static unsigned int status_count = 0; +static guint status_count = 0; #ifdef HAVE_LIBNOTIFY static gboolean notification_callback (gpointer notify); @@ -370,7 +370,7 @@ static void do_properties (GtkMenuItem *item, gpointer user_data) { GtkWidget *cfg, *dialog, *vbox, *label, *hbox; - char *text; + gchar *text; cfg = get_cfg_widget (); if (!cfg) @@ -465,7 +465,7 @@ notifyActionCallback (NotifyNotification *n, gchar *label, gpointer a) static void new_notify_status (EMEventTargetFolder *t) { - char *msg; + gchar *msg; gboolean new_icon = !status_icon; if (new_icon) { @@ -541,7 +541,7 @@ read_notify_status (EMEventTargetMessage *t) } static void -enable_status (int enable) +enable_status (gint enable) { /* this does nothing on enable, it's here just to be consistent with other parts of this plugin */ @@ -730,7 +730,7 @@ read_notify_sound (EMEventTargetMessage *t) } static void -enable_sound (int enable) +enable_sound (gint enable) { if (enable) gnome_sound_init ("localhost"); @@ -854,7 +854,7 @@ get_cfg_widget (void) void org_gnome_mail_new_notify (EPlugin *ep, EMEventTargetFolder *t); void org_gnome_mail_read_notify (EPlugin *ep, EMEventTargetMessage *t); -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); GtkWidget *e_plugin_lib_get_configure_widget (EPlugin *epl); @@ -904,8 +904,8 @@ org_gnome_mail_read_notify (EPlugin *ep, EMEventTargetMessage *t) g_static_mutex_unlock (&mlock); } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { if (enable) { #ifdef HAVE_DBUS diff --git a/plugins/mail-to-task/mail-to-task.c b/plugins/mail-to-task/mail-to-task.c index 5560a4cabd..78fd37b999 100644 --- a/plugins/mail-to-task/mail-to-task.c +++ b/plugins/mail-to-task/mail-to-task.c @@ -53,14 +53,14 @@ #include <gtkhtml/gtkhtml.h> #include <calendar/common/authentication.h> -static char * -clean_name(const unsigned char *s) +static gchar * +clean_name(const guchar *s) { GString *out = g_string_new(""); guint32 c; - char *r; + gchar *r; - while ((c = camel_utf8_getc ((const unsigned char **)&s))) + while ((c = camel_utf8_getc ((const guchar **)&s))) { if (!g_unichar_isprint (c) || ( c < 0x7f && strchr (" /'\"`&();|<>$%{}!", c ))) c = '_'; @@ -74,12 +74,12 @@ clean_name(const unsigned char *s) } static void -set_attendees (ECalComponent *comp, CamelMimeMessage *message, const char *organizer) +set_attendees (ECalComponent *comp, CamelMimeMessage *message, const gchar *organizer) { GSList *attendees = NULL, *to_free = NULL; ECalComponentAttendee *ca; const CamelInternetAddress *from = NULL, *to, *cc, *bcc, *arr[4]; - int len, i, j; + gint len, i, j; if (message->reply_to) from = message->reply_to; @@ -98,10 +98,10 @@ set_attendees (ECalComponent *comp, CamelMimeMessage *message, const char *organ len = CAMEL_ADDRESS (arr[j])->addresses->len; for (i = 0; i < len; i++) { - const char *name, *addr; + const gchar *name, *addr; if (camel_internet_address_get (arr[j], i, &name, &addr)) { - char *temp; + gchar *temp; temp = g_strconcat ("mailto:", addr, NULL); if (organizer && g_ascii_strcasecmp (temp, organizer) == 0) { @@ -152,7 +152,7 @@ set_description (ECalComponent *comp, CamelMimeMessage *message) CamelMimePart *mime_part = CAMEL_MIME_PART (message); ECalComponentText text; GSList sl; - char *str, *convert_str = NULL; + gchar *str, *convert_str = NULL; gsize bytes_read, bytes_written; gint count = 2; @@ -180,7 +180,7 @@ set_description (ECalComponent *comp, CamelMimeMessage *message) mem = camel_stream_mem_new (); camel_data_wrapper_decode_to_stream (content, mem); - str = g_strndup ((const gchar*)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len); + str = g_strndup ((const gchar *)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len); camel_object_unref (mem); /* convert to UTF-8 string */ @@ -206,13 +206,13 @@ set_description (ECalComponent *comp, CamelMimeMessage *message) g_free (convert_str); } -static char * +static gchar * set_organizer (ECalComponent *comp) { EAccount *account; - const char *str, *name; + const gchar *str, *name; ECalComponentOrganizer organizer = {NULL, NULL, NULL, NULL}; - char *res; + gchar *res; account = mail_config_get_default_account (); if (!account) @@ -235,11 +235,11 @@ set_organizer (ECalComponent *comp) static void set_attachments (ECal *client, ECalComponent *comp, CamelMimeMessage *message) { - int parts, i; + gint parts, i; GSList *list = NULL; - const char *uid; - const char *store_uri; - char *store_dir; + const gchar *uid; + const gchar *store_uri; + gchar *store_dir; CamelDataWrapper *content; content = camel_medium_get_content_object ((CamelMedium *) message); @@ -258,8 +258,8 @@ set_attachments (ECal *client, ECalComponent *comp, CamelMimeMessage *message) for (i = 1; i < parts; i++) { - char *filename, *path, *tmp; - const char *orig_filename; + gchar *filename, *path, *tmp; + const gchar *orig_filename; CamelMimePart *mime_part; mime_part = camel_multipart_get_part (CAMEL_MULTIPART (content), i); @@ -268,13 +268,13 @@ set_attachments (ECal *client, ECalComponent *comp, CamelMimeMessage *message) if (!orig_filename) continue; - tmp = clean_name ((const unsigned char *)orig_filename); + tmp = clean_name ((const guchar *)orig_filename); filename = g_strdup_printf ("%s-%s", uid, tmp); path = g_build_filename (store_dir, filename, NULL); if (em_utils_save_part_to_file (NULL, path, mime_part)) { - char *uri; + gchar *uri; uri = g_filename_to_uri (path, NULL, NULL); list = g_slist_append (list, g_strdup (uri)); g_free (uri); @@ -292,8 +292,8 @@ set_attachments (ECal *client, ECalComponent *comp, CamelMimeMessage *message) struct _report_error { - char *format; - char *param; + gchar *format; + gchar *param; }; static gboolean @@ -310,7 +310,7 @@ do_report_error (struct _report_error *err) } static void -report_error_idle (const char *format, const char *param) +report_error_idle (const gchar *format, const gchar *param) { struct _report_error *err = g_new (struct _report_error, 1); @@ -325,7 +325,7 @@ typedef struct { ECal *client; struct _CamelFolder *folder; GPtrArray *uids; - char *selected_text; + gchar *selected_text; gboolean with_attendees; }AsyncData; @@ -361,7 +361,7 @@ do_mail_to_event (AsyncData *data) } } } else { - int i; + gint i; ECalSourceType source_type = e_cal_get_source_type (client); ECalComponentDateTime dt, dt2; struct icaltimetype tt, tt2; @@ -433,7 +433,7 @@ do_mail_to_event (AsyncData *data) set_description (comp, message); if (data->with_attendees) { - char *organizer; + gchar *organizer; /* set actual user as organizer, to be able to change event's properties */ organizer = set_organizer (comp); @@ -477,15 +477,15 @@ do_mail_to_event (AsyncData *data) } static void -copy_uids (char *uid, GPtrArray *uid_array) +copy_uids (gchar *uid, GPtrArray *uid_array) { g_ptr_array_add (uid_array, g_strdup (uid)); } static gboolean -text_contains_nonwhitespace (const char *text, gint len) +text_contains_nonwhitespace (const gchar *text, gint len) { - const char *p; + const gchar *p; gunichar c = 0; if (!text || len<=0) @@ -508,10 +508,10 @@ text_contains_nonwhitespace (const char *text, gint len) } /* should be freed with g_free after done with it */ -static char * +static gchar * get_selected_text (EMFolderView *emfv) { - char *text = NULL; + gchar *text = NULL; gint len; if (!emfv || !emfv->preview || !gtk_html_command (((EMFormatHTML *)emfv->preview)->html, "is-selection-active")) @@ -602,7 +602,7 @@ mail_to_event (ECalSourceType source_type, gboolean with_attendees, GPtrArray *u client = auth_new_cal_from_source (source, source_type); if (!client) { - char *uri = e_source_get_uri (source); + gchar *uri = e_source_get_uri (source); e_notice (NULL, GTK_MESSAGE_ERROR, "Could not create the client: %s", uri); @@ -635,24 +635,24 @@ mail_to_event (ECalSourceType source_type, gboolean with_attendees, GPtrArray *u /* ************************************************************************* */ -int e_plugin_lib_enable (EPluginLib *ep, int enable); -void org_gnome_mail_to_event (void *ep, EMPopupTargetSelect *t); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); +void org_gnome_mail_to_event (gpointer ep, EMPopupTargetSelect *t); void org_gnome_mail_to_event_menu (EPlugin *ep, EMMenuTargetSelect *t); -void org_gnome_mail_to_meeting (void *ep, EMPopupTargetSelect *t); +void org_gnome_mail_to_meeting (gpointer ep, EMPopupTargetSelect *t); void org_gnome_mail_to_meeting_menu (EPlugin *ep, EMMenuTargetSelect *t); -void org_gnome_mail_to_task (void *ep, EMPopupTargetSelect *t); +void org_gnome_mail_to_task (gpointer ep, EMPopupTargetSelect *t); void org_gnome_mail_to_task_menu (EPlugin *ep, EMMenuTargetSelect *t); -void org_gnome_mail_to_memo (void *ep, EMPopupTargetSelect *t); +void org_gnome_mail_to_memo (gpointer ep, EMPopupTargetSelect *t); void org_gnome_mail_to_memo_menu (EPlugin *ep, EMMenuTargetSelect *t); -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { return 0; } void -org_gnome_mail_to_event (void *ep, EMPopupTargetSelect *t) +org_gnome_mail_to_event (gpointer ep, EMPopupTargetSelect *t) { mail_to_event (E_CAL_SOURCE_TYPE_EVENT, FALSE, t->uids, t->folder, (EMFolderView *) t->target.widget); } @@ -664,7 +664,7 @@ org_gnome_mail_to_event_menu (EPlugin *ep, EMMenuTargetSelect *t) } void -org_gnome_mail_to_meeting (void *ep, EMPopupTargetSelect *t) +org_gnome_mail_to_meeting (gpointer ep, EMPopupTargetSelect *t) { mail_to_event (E_CAL_SOURCE_TYPE_EVENT, TRUE, t->uids, t->folder, (EMFolderView *) t->target.widget); } @@ -676,7 +676,7 @@ org_gnome_mail_to_meeting_menu (EPlugin *ep, EMMenuTargetSelect *t) } void -org_gnome_mail_to_task (void *ep, EMPopupTargetSelect *t) +org_gnome_mail_to_task (gpointer ep, EMPopupTargetSelect *t) { mail_to_event (E_CAL_SOURCE_TYPE_TODO, TRUE, t->uids, t->folder, (EMFolderView *) t->target.widget); } @@ -688,7 +688,7 @@ org_gnome_mail_to_task_menu (EPlugin *ep, EMMenuTargetSelect *t) } void -org_gnome_mail_to_memo (void *ep, EMPopupTargetSelect *t) +org_gnome_mail_to_memo (gpointer ep, EMPopupTargetSelect *t) { /* do not set organizer and attendees for memos */ mail_to_event (E_CAL_SOURCE_TYPE_JOURNAL, FALSE, t->uids, t->folder, (EMFolderView *) t->target.widget); diff --git a/plugins/mailing-list-actions/mailing-list-actions.c b/plugins/mailing-list-actions/mailing-list-actions.c index 7dc1895389..f3ca8d1651 100644 --- a/plugins/mailing-list-actions/mailing-list-actions.c +++ b/plugins/mailing-list-actions/mailing-list-actions.c @@ -58,7 +58,7 @@ typedef enum { typedef struct { EmlaAction action; /* action enumeration */ gboolean interactive; /* whether the user needs to edit a mailto: message (e.g. for post action) */ - const char* header; /* header representing the action */ + const gchar * header; /* header representing the action */ } EmlaActionHeader; const EmlaActionHeader emla_action_headers[] = { @@ -70,7 +70,7 @@ const EmlaActionHeader emla_action_headers[] = { { EMLA_ACTION_ARCHIVE, FALSE, "List-Archive" }, }; -const int emla_n_action_headers = sizeof(emla_action_headers) / sizeof(EmlaActionHeader); +const gint emla_n_action_headers = sizeof(emla_action_headers) / sizeof(EmlaActionHeader); void emla_list_action (EPlugin *item, EMMenuTargetSelect* sel, EmlaAction action); void emla_list_help (EPlugin *item, EMMenuTargetSelect* sel); @@ -80,11 +80,11 @@ void emla_list_post (EPlugin *item, EMMenuTargetSelect* sel); void emla_list_owner (EPlugin *item, EMMenuTargetSelect* sel); void emla_list_archive (EPlugin *item, EMMenuTargetSelect* sel); -void emla_list_action_do (CamelFolder *folder, const char *uid, CamelMimeMessage *msg, void *data); +void emla_list_action_do (CamelFolder *folder, const gchar *uid, CamelMimeMessage *msg, gpointer data); typedef struct { EmlaAction action; - char* uri; + gchar * uri; } emla_action_data; void emla_list_action (EPlugin *item, EMMenuTargetSelect* sel, EmlaAction action) @@ -97,19 +97,19 @@ void emla_list_action (EPlugin *item, EMMenuTargetSelect* sel, EmlaAction action data->action = action; data->uri = strdup (sel->uri); - mail_get_message (sel->folder, (const char*) g_ptr_array_index (sel->uids, 0), + mail_get_message (sel->folder, (const gchar *) g_ptr_array_index (sel->uids, 0), emla_list_action_do, data, mail_msg_unordered_push); } -void emla_list_action_do (CamelFolder *folder, const char *uid, CamelMimeMessage *msg, void *data) +void emla_list_action_do (CamelFolder *folder, const gchar *uid, CamelMimeMessage *msg, gpointer data) { emla_action_data *action_data = (emla_action_data *) data; EmlaAction action = action_data->action; - const char* header = NULL, *headerpos; - char *end, *url = NULL; - int t; + const gchar * header = NULL, *headerpos; + gchar *end, *url = NULL; + gint t; EMsgComposer *composer; - int send_message_response; + gint send_message_response; EAccount *account; if (msg == NULL) diff --git a/plugins/mark-all-read/mark-all-read.c b/plugins/mark-all-read/mark-all-read.c index dfcf75937b..87f52183fd 100644 --- a/plugins/mark-all-read/mark-all-read.c +++ b/plugins/mark-all-read/mark-all-read.c @@ -42,7 +42,7 @@ "only, or in the current folder as well as all subfolders?") void org_gnome_mark_all_read (EPlugin *ep, EMPopupTargetFolder *target); -static void mar_got_folder (char *uri, CamelFolder *folder, void *data); +static void mar_got_folder (gchar *uri, CamelFolder *folder, gpointer data); static void mar_all_sub_folders (CamelStore *store, CamelFolderInfo *fi, CamelException *ex); static void @@ -204,7 +204,7 @@ static void mark_all_as_read (CamelFolder *folder) { GPtrArray *uids; - int i; + gint i; uids = camel_folder_get_uids (folder); camel_folder_freeze(folder); @@ -215,7 +215,7 @@ mark_all_as_read (CamelFolder *folder) } static void -mar_got_folder (char *uri, CamelFolder *folder, void *data) +mar_got_folder (gchar *uri, CamelFolder *folder, gpointer data) { CamelFolderInfo *info; CamelStore *store; diff --git a/plugins/mono/mono-plugin.c b/plugins/mono/mono-plugin.c index 0bc95619ce..c7feb024b0 100644 --- a/plugins/mono/mono-plugin.c +++ b/plugins/mono/mono-plugin.c @@ -37,7 +37,7 @@ static MonoDomain *domain; /* ********************************************************************** */ -static void *epm_parent_class; +static gpointer epm_parent_class; typedef struct _EPluginMonoPrivate { MonoAssembly *assembly; @@ -48,13 +48,13 @@ typedef struct _EPluginMonoPrivate { #define epm ((EPluginMono *)ep) -void * load_plugin_type_register_function (void *a, void *b); +gpointer load_plugin_type_register_function (gpointer a, gpointer b); -static char * -get_xml_prop(xmlNodePtr node, const char *id) +static gchar * +get_xml_prop(xmlNodePtr node, const gchar *id) { - char *p = xmlGetProp(node, id); - char *out = NULL; + gchar *p = xmlGetProp(node, id); + gchar *out = NULL; if (p) { out = g_strdup(p); @@ -72,14 +72,14 @@ get_xml_prop(xmlNodePtr node, const char *id) All methods take a single (structured) argument. */ -static void * -epm_invoke(EPlugin *ep, const char *name, void *data) +static gpointer +epm_invoke(EPlugin *ep, const gchar *name, gpointer data) { EPluginMonoPrivate *p = epm->priv; MonoMethodDesc *d; MonoMethod *m; MonoObject *x = NULL, *res; - void **params; + gpointer *params; g_print ("\n\a epm_invoke in mono-plugin.c in mono plugin loader is called \n\a"); @@ -158,7 +158,7 @@ epm_invoke(EPlugin *ep, const char *name, void *data) mono_print_unhandled_exception(x); if (res) { - void **p = mono_object_unbox(res); + gpointer *p = mono_object_unbox(res); d(printf("mono method returned '%p' %ld\n", *p, (long int)*p)); return *p; } else @@ -217,8 +217,8 @@ epm_init(GObject *o) (GDestroyNotify) NULL); } -void * -load_plugin_type_register_function (void *a, void *b) +gpointer +load_plugin_type_register_function (gpointer a, gpointer b) { static GType type = 0; diff --git a/plugins/mono/mono-plugin.h b/plugins/mono/mono-plugin.h index 9dd8facdb3..8ea867e806 100644 --- a/plugins/mono/mono-plugin.h +++ b/plugins/mono/mono-plugin.h @@ -38,14 +38,14 @@ struct _EPluginMono { struct _EPluginMonoPrivate *priv; - char *location; /* location */ - char *handler; /* handler class */ + gchar *location; /* location */ + gchar *handler; /* handler class */ }; struct _EPluginMonoClass { EPluginClass plugin_class; }; -void *org_gnome_evolution_mono_get_type(void *a, void *b); +gpointer org_gnome_evolution_mono_get_type(gpointer a, gpointer b); #endif /* ! _ORG_GNOME_EVOLUTION_MONO_H */ diff --git a/plugins/plugin-manager/plugin-manager.c b/plugins/plugin-manager/plugin-manager.c index 54d166065b..816505b662 100644 --- a/plugins/plugin-manager/plugin-manager.c +++ b/plugins/plugin-manager/plugin-manager.c @@ -52,7 +52,7 @@ enum }; static struct { - const char *label; + const gchar *label; } label_info[LABEL_LAST] = { { N_("Name"), }, { N_("Author(s)"), }, @@ -81,10 +81,10 @@ static GtkWidget *configure_page; static gint last_selected_page; static gulong switch_page_handler_id; -void org_gnome_plugin_manager_manage(void *ep, ESMenuTargetShell *t); +void org_gnome_plugin_manager_manage(gpointer ep, ESMenuTargetShell *t); static void -eppm_set_label (GtkLabel *l, const char *v) +eppm_set_label (GtkLabel *l, const gchar *v) { gtk_label_set_label(l, v?v:_("Unknown")); } @@ -101,7 +101,7 @@ static void eppm_show_plugin (Manager *m, EPlugin *ep, GtkWidget *cfg_widget) { if (ep) { - char *string; + gchar *string; string = g_strdup_printf ("<span size=\"x-large\">%s</span>", ep->name); gtk_label_set_markup (GTK_LABEL (m->items[LABEL_NAME]), string); @@ -133,7 +133,7 @@ eppm_show_plugin (Manager *m, EPlugin *ep, GtkWidget *cfg_widget) eppm_set_label (m->items[LABEL_DESCRIPTION], ep->description); } else { - int i; + gint i; gtk_label_set_markup (GTK_LABEL (m->config_plugin_label), ""); for (i = 0; i < LABEL_LAST; i++) @@ -184,7 +184,7 @@ eppm_selection_changed (GtkTreeSelection *selection, Manager *m) } static void -eppm_enable_toggled (GtkCellRendererToggle *renderer, const char *path_string, Manager *m) +eppm_enable_toggled (GtkCellRendererToggle *renderer, const gchar *path_string, Manager *m) { GtkTreePath *path; GtkTreeIter iter; @@ -207,7 +207,7 @@ eppm_enable_toggled (GtkCellRendererToggle *renderer, const char *path_string, M } static void -eppm_free (void *data) +eppm_free (gpointer data) { Manager *m = data; GSList *l; @@ -221,24 +221,24 @@ eppm_free (void *data) } static void -eppm_response (GtkDialog *w, int button, Manager *m) +eppm_response (GtkDialog *w, gint button, Manager *m) { gtk_widget_destroy (GTK_WIDGET (w)); dialog = NULL; } void -org_gnome_plugin_manager_manage (void *ep, ESMenuTargetShell *t) +org_gnome_plugin_manager_manage (gpointer ep, ESMenuTargetShell *t) { Manager *m; - int i; + gint i; GtkWidget *hbox, *w; GtkWidget *overview_page; GtkListStore *store; GtkTreeSelection *selection; GtkCellRenderer *renderer; GSList *l; - char *string; + gchar *string; GtkWidget *subvbox; if (dialog) { @@ -391,7 +391,7 @@ org_gnome_plugin_manager_manage (void *ep, ESMenuTargetShell *t) /* this is every other data */ for (i = 1; i < LABEL_LAST; i++) { - char *markup; + gchar *markup; subvbox = gtk_vbox_new (FALSE, 6); @@ -431,10 +431,10 @@ org_gnome_plugin_manager_manage (void *ep, ESMenuTargetShell *t) gtk_widget_show (GTK_WIDGET (m->dialog)); } -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { if (enable) { } else { diff --git a/plugins/prefer-plain/prefer-plain.c b/plugins/prefer-plain/prefer-plain.c index 13453b20f1..dd7e4539b8 100644 --- a/plugins/prefer-plain/prefer-plain.c +++ b/plugins/prefer-plain/prefer-plain.c @@ -37,8 +37,8 @@ #include <gconf/gconf-client.h> #include "mail/em-config.h" -void org_gnome_prefer_plain_multipart_alternative(void *ep, EMFormatHookTarget *t); -void org_gnome_prefer_plain_text_html(void *ep, EMFormatHookTarget *t); +void org_gnome_prefer_plain_multipart_alternative(gpointer ep, EMFormatHookTarget *t); +void org_gnome_prefer_plain_text_html(gpointer ep, EMFormatHookTarget *t); GtkWidget *org_gnome_prefer_plain_config_mode(struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data); enum { @@ -48,10 +48,10 @@ enum { }; static GConfClient *epp_gconf = NULL; -static int epp_mode = -1; +static gint epp_mode = -1; void -org_gnome_prefer_plain_text_html(void *ep, EMFormatHookTarget *t) +org_gnome_prefer_plain_text_html(gpointer ep, EMFormatHookTarget *t) { /* In text-only mode, all html output is suppressed */ if (epp_mode != EPP_TEXT) @@ -63,7 +63,7 @@ org_gnome_prefer_plain_text_html(void *ep, EMFormatHookTarget *t) static void export_as_attachments (CamelMultipart *mp, EMFormat *format, CamelStream *stream, CamelMimePart *except) { - int i, nparts, partidlen; + gint i, nparts, partidlen; CamelMimePart *part; if (!mp || !CAMEL_IS_MULTIPART (mp)) @@ -88,7 +88,7 @@ export_as_attachments (CamelMultipart *mp, EMFormat *format, CamelStream *stream camel_mime_part_set_disposition (part, "attachment"); if (!camel_mime_part_get_filename (part)) { - char *str = g_strdup_printf ("%s.html", _("attachment")); + gchar *str = g_strdup_printf ("%s.html", _("attachment")); camel_mime_part_set_filename (part, str); g_free (str); } @@ -104,11 +104,11 @@ export_as_attachments (CamelMultipart *mp, EMFormat *format, CamelStream *stream } void -org_gnome_prefer_plain_multipart_alternative(void *ep, EMFormatHookTarget *t) +org_gnome_prefer_plain_multipart_alternative(gpointer ep, EMFormatHookTarget *t) { CamelMultipart *mp = (CamelMultipart *)camel_medium_get_content_object((CamelMedium *)t->part); CamelMimePart *part, *display_part = NULL; - int i, nparts, partidlen, displayid = 0; + gint i, nparts, partidlen, displayid = 0; /* FIXME: this part-id stuff is poking private data, needs api */ partidlen = t->format->part_id->len; @@ -183,8 +183,8 @@ org_gnome_prefer_plain_multipart_alternative(void *ep, EMFormatHookTarget *t) } static struct { - const char *label; - const char *key; + const gchar *label; + const gchar *key; } epp_options[] = { { N_("Show HTML if present"), "normal" }, { N_("Prefer PLAIN"), "prefer_plain" }, @@ -192,7 +192,7 @@ static struct { }; static void -epp_mode_changed(GtkComboBox *dropdown, void *dummy) +epp_mode_changed(GtkComboBox *dropdown, gpointer dummy) { epp_mode = gtk_combo_box_get_active(dropdown); if (epp_mode > 2) @@ -209,7 +209,7 @@ org_gnome_prefer_plain_config_mode(struct _EPlugin *epl, struct _EConfigHookItem GtkCellRenderer *cell; GtkListStore *store; GtkWidget *w; - int i; + gint i; GtkTreeIter iter; if (data->old) @@ -243,13 +243,13 @@ org_gnome_prefer_plain_config_mode(struct _EPlugin *epl, struct _EConfigHookItem return (GtkWidget *)dropdown; } -int e_plugin_lib_enable(EPluginLib *ep, int enable); +gint e_plugin_lib_enable(EPluginLib *ep, gint enable); -int -e_plugin_lib_enable(EPluginLib *ep, int enable) +gint +e_plugin_lib_enable(EPluginLib *ep, gint enable) { - char *key; - int i; + gchar *key; + gint i; if (epp_gconf || epp_mode != -1) return 0; diff --git a/plugins/profiler/profiler.c b/plugins/profiler/profiler.c index 08787fc1fc..94984a3560 100644 --- a/plugins/profiler/profiler.c +++ b/plugins/profiler/profiler.c @@ -38,7 +38,7 @@ org_gnome_evolution_profiler_event(EPlugin *ep, EProfileEventTarget *t) static FILE *fp; if (!fp) { - char *name; + gchar *name; name = g_strdup_printf("eprofile.%ld", (long int)getpid()); fp = fopen(name, "w"); diff --git a/plugins/pst-import/pst-importer.c b/plugins/pst-import/pst-importer.c index 4bfe66b41f..9c9f3ad244 100644 --- a/plugins/pst-import/pst-importer.c +++ b/plugins/pst-import/pst-importer.c @@ -72,9 +72,9 @@ typedef struct _PstImporter PstImporter; -int pst_init (pst_file *pst, char *filename); +gint pst_init (pst_file *pst, gchar *filename); gchar *get_pst_rootname (pst_file *pst, gchar *filename); -static void pst_error_msg (const char *fmt, ...); +static void pst_error_msg (const gchar *fmt, ...); static void pst_import_folders (PstImporter *m, pst_desc_ll *topitem); static void pst_process_item (PstImporter *m, pst_desc_ll *d_ptr); static void pst_process_folder (PstImporter *m, pst_item *item); @@ -89,13 +89,13 @@ gchar *foldername_to_utf8 (const gchar *pstname); gchar *string_to_utf8(const gchar *string); void contact_set_date (EContact *contact, EContactField id, FILETIME *date); struct icaltimetype get_ical_date (FILETIME *date, gboolean is_date); -char *rfc2445_datetime_format (FILETIME *ft); +gchar *rfc2445_datetime_format (FILETIME *ft); gboolean org_credativ_evolution_readpst_supported (EPlugin *epl, EImportTarget *target); GtkWidget *org_credativ_evolution_readpst_getwidget (EImport *ei, EImportTarget *target, EImportImporter *im); void org_credativ_evolution_readpst_import (EImport *ei, EImportTarget *target, EImportImporter *im); void org_credativ_evolution_readpst_cancel (EImport *ei, EImportTarget *target, EImportImporter *im); -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); /* em-folder-selection-button.h is private, even though other internal evo plugins use it! @@ -103,11 +103,11 @@ int e_plugin_lib_enable (EPluginLib *ep, int enable); TODO: sort out whether this should really be private */ typedef struct _EMFolderSelectionButton EMFolderSelectionButton; -GtkWidget *em_folder_selection_button_new (const char *title, const char *caption); -void em_folder_selection_button_set_selection (EMFolderSelectionButton *button, const char *uri); -const char *em_folder_selection_button_get_selection (EMFolderSelectionButton *button); +GtkWidget *em_folder_selection_button_new (const gchar *title, const gchar *caption); +void em_folder_selection_button_set_selection (EMFolderSelectionButton *button, const gchar *uri); +const gchar *em_folder_selection_button_get_selection (EMFolderSelectionButton *button); -static unsigned char pst_signature [] = { '!', 'B', 'D', 'N' }; +static guchar pst_signature [] = { '!', 'B', 'D', 'N' }; struct _PstImporter { MailMsg base; @@ -116,9 +116,9 @@ struct _PstImporter { EImportTarget *target; GMutex *status_lock; - char *status_what; - int status_pc; - int status_timeout_id; + gchar *status_what; + gint status_pc; + gint status_timeout_id; CamelOperation *status; CamelException ex; @@ -129,8 +129,8 @@ struct _PstImporter { gchar *parent_uri; gchar *folder_name; gchar *folder_uri; - int folder_count; - int current_item; + gint folder_count; + gint current_item; EBook *addressbook; ECal *calendar; @@ -141,11 +141,11 @@ struct _PstImporter { gboolean org_credativ_evolution_readpst_supported (EPlugin *epl, EImportTarget *target) { - char signature[sizeof (pst_signature)]; + gchar signature[sizeof (pst_signature)]; gboolean ret = FALSE; - int fd, n; + gint fd, n; EImportTargetURI *s; - char *filename; + gchar *filename; if (target->type != E_IMPORT_TARGET_URI) { return FALSE; @@ -217,7 +217,7 @@ folder_selected (EMFolderSelectionButton *button, EImportTargetURI *target) * @param target * @return */ -static gchar* +static gchar * get_suggested_foldername (EImportTargetURI *target) { const gchar *inbox; @@ -259,7 +259,7 @@ get_suggested_foldername (EImportTargetURI *target) if (mail_tool_uri_to_folder (foldername->str, 0, NULL) != NULL) { /* Folder exists - add a number */ - int i, len; + gint i, len; len = foldername->len; CamelFolder *folder; @@ -346,14 +346,14 @@ org_credativ_evolution_readpst_getwidget (EImport *ei, EImportTarget *target, EI return framebox; } -static char * -pst_import_describe (PstImporter *m, int complete) +static gchar * +pst_import_describe (PstImporter *m, gint complete) { return g_strdup (_("Importing Outlook data")); } static ECal* -open_ecal (ECalSourceType type, char *name) +open_ecal (ECalSourceType type, gchar *name) { /* Hack - grab the first calendar we can find TODO - add a selection mechanism in get_widget */ @@ -446,7 +446,7 @@ pst_import_import (PstImporter *m) static void pst_import_file (PstImporter *m) { - int ret; + gint ret; gchar *filename; pst_item *item = NULL; pst_desc_ll *d_ptr; @@ -689,7 +689,7 @@ pst_create_folder (PstImporter *m) { const gchar *parent; gchar *dest, *dest_end, *pos; - int dest_len; + gint dest_len; parent = ((EImportTargetURI *)m->target)->uri_dest; dest = g_strdup (m->folder_uri); @@ -733,7 +733,7 @@ static CamelMimePart * attachment_to_part (PstImporter *m, pst_item_attach *attach) { CamelMimePart *part; - char *mimetype; + gchar *mimetype; part = camel_mime_part_new (); @@ -754,11 +754,11 @@ attachment_to_part (PstImporter *m, pst_item_attach *attach) if (attach->data != NULL) { camel_mime_part_set_content (part, attach->data, strlen (attach->data), mimetype); } else { - char *buf = NULL; + gchar *buf = NULL; size_t size; size = pst_attach_to_mem (&m->pst, attach, &buf); - camel_mime_part_set_content (part, (char*) buf, size, mimetype); + camel_mime_part_set_content (part, (gchar *) buf, size, mimetype); free(buf); } @@ -942,7 +942,7 @@ pst_process_email (PstImporter *m, pst_item *item) } static void -contact_set_string (EContact *contact, EContactField id, char *string) +contact_set_string (EContact *contact, EContactField id, gchar *string) { if (string != NULL) { e_contact_set (contact, id, string); @@ -950,7 +950,7 @@ contact_set_string (EContact *contact, EContactField id, char *string) } static void -unknown_field (EContact *contact, GString *notes, char *name, char *string) +unknown_field (EContact *contact, GString *notes, gchar *name, gchar *string) { /* Field could not be mapped directly so add to notes field */ if (string != NULL) { @@ -959,7 +959,7 @@ unknown_field (EContact *contact, GString *notes, char *name, char *string) } static void -contact_set_address (EContact *contact, EContactField id, char *address, char *city, char *country, char *po_box, char *postal_code, char *state, char *street) +contact_set_address (EContact *contact, EContactField id, gchar *address, gchar *city, gchar *country, gchar *po_box, gchar *postal_code, gchar *state, gchar *street) { EContactAddress *eaddress; @@ -1181,8 +1181,8 @@ get_ical_date (FILETIME *date, gboolean is_date) } } -char *rfc2445_datetime_format (FILETIME *ft) { - static char* buffer = NULL; +gchar *rfc2445_datetime_format (FILETIME *ft) { + static gchar * buffer = NULL; struct tm *stm = NULL; if (buffer == NULL) { @@ -1198,8 +1198,8 @@ static void set_cal_attachments (ECal *cal, ECalComponent *ec, PstImporter *m, pst_item_attach *attach) { GSList *list = NULL; - const char *uid; - char *store_dir; + const gchar *uid; + gchar *store_dir; if (attach == NULL) { return; @@ -1209,8 +1209,8 @@ set_cal_attachments (ECal *cal, ECalComponent *ec, PstImporter *m, pst_item_atta store_dir = g_filename_from_uri (e_cal_get_local_attachment_store (cal), NULL, NULL); while (attach != NULL) { - const char* orig_filename; - char *filename, *tmp, *path, *dirname, *uri; + const gchar * orig_filename; + gchar *filename, *tmp, *path, *dirname, *uri; CamelMimePart *part; CamelDataWrapper *content; CamelStream *stream; @@ -1292,7 +1292,7 @@ set_cal_attachments (ECal *cal, ECalComponent *ec, PstImporter *m, pst_item_atta } static void -fill_calcomponent (PstImporter *m, pst_item *item, ECalComponent *ec, const char *type) +fill_calcomponent (PstImporter *m, pst_item *item, ECalComponent *ec, const gchar *type) { pst_item_appointment *a; pst_item_email *e; @@ -1537,7 +1537,7 @@ pst_process_journal (PstImporter *m, pst_item *item) /* Print an error message - maybe later bring up an error dialog? */ static void -pst_error_msg (const char *fmt, ...) +pst_error_msg (const gchar *fmt, ...) { va_list ap; @@ -1580,11 +1580,11 @@ static MailMsgInfo pst_import_info = { }; static gboolean -pst_status_timeout (void *data) +pst_status_timeout (gpointer data) { PstImporter *importer = data; - int pc; - char *what; + gint pc; + gchar *what; if (importer->status_what) { g_mutex_lock (importer->status_lock); @@ -1600,7 +1600,7 @@ pst_status_timeout (void *data) } static void -pst_status (CamelOperation *op, const char *what, int pc, void *data) +pst_status (CamelOperation *op, const gchar *what, gint pc, gpointer data) { PstImporter *importer = data; @@ -1621,7 +1621,7 @@ static int pst_import (EImport *ei, EImportTarget *target) { PstImporter *m; - int id; + gint id; m = mail_msg_new (&pst_import_info); g_datalist_set_data (&target->data, "pst-msg", m); @@ -1675,8 +1675,8 @@ org_credativ_evolution_readpst_cancel (EImport *ei, EImportTarget *target, EImpo } } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { if (enable) { bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); @@ -1695,12 +1695,12 @@ e_plugin_lib_enable (EPluginLib *ep, int enable) * @param filename : path to file * @return 0 for sucess, -1 for failure */ -int +gint pst_init (pst_file *pst, gchar *filename) { #if 0 - char *d_log = "readpst.log"; + gchar *d_log = "readpst.log"; /* initialize log file */ DEBUG_INIT (d_log); DEBUG_REGISTER_CLOSE (); diff --git a/plugins/publish-calendar/publish-calendar.c b/plugins/publish-calendar/publish-calendar.c index 943f0ed933..ad6e38e9f9 100644 --- a/plugins/publish-calendar/publish-calendar.c +++ b/plugins/publish-calendar/publish-calendar.c @@ -47,9 +47,9 @@ static gint online = 0; static GSList *error_queue = NULL; static GStaticMutex error_queue_lock = G_STATIC_MUTEX_INIT; static guint error_queue_show_idle_id = 0; -static void error_queue_add (char *descriptions, GError *error); +static void error_queue_add (gchar *descriptions, GError *error); -int e_plugin_lib_enable (EPlugin *ep, int enable); +gint e_plugin_lib_enable (EPlugin *ep, gint enable); void action_publish (EPlugin *ep, ECalMenuTargetSelect *t); void online_state_changed (EPlugin *ep, ESEventTargetState *target); void publish_calendar_context_activate (EPlugin *ep, ECalPopupTargetSource *target); @@ -233,14 +233,14 @@ ask_password (GMountOperation *op, const gchar *message, const gchar *default_us } static void -ask_question (GMountOperation *op, const char *message, const char *choices[]) +ask_question (GMountOperation *op, const gchar *message, const gchar *choices[]) { /* this has been stolen from file-chooser */ GtkWidget *dialog; - int cnt, len; - char *primary; - const char *secondary = NULL; - int res; + gint cnt, len; + gchar *primary; + const gchar *secondary = NULL; + gint res; primary = strstr (message, "\n"); if (primary) { @@ -452,7 +452,7 @@ url_list_changed (PublishUIData *ui) valid = gtk_tree_model_get_iter_first (model, &iter); while (valid) { EPublishUri *url; - char *xml; + gchar *xml; gtk_tree_model_get (model, &iter, URL_LIST_URL_COLUMN, &url, -1); @@ -469,7 +469,7 @@ url_list_changed (PublishUIData *ui) static void url_list_enable_toggled (GtkCellRendererToggle *renderer, - const char *path_string, + const gchar *path_string, PublishUIData *ui) { GtkTreeSelection *selection; @@ -618,7 +618,7 @@ url_remove_clicked (GtkButton *button, PublishUIData *ui) gtk_widget_destroy (confirm); if (response == GTK_RESPONSE_YES) { - int len; + gint len; guint id; gtk_list_store_remove (GTK_LIST_STORE (model), &iter); @@ -685,7 +685,7 @@ publish_calendar_locations (EPlugin *epl, EConfigHookItemFactoryData *data) GSList *l; GtkTreeIter iter; GConfClient *client; - char *gladefile; + gchar *gladefile; gladefile = g_build_filename (EVOLUTION_GLADEDIR, "publish-calendar.glade", @@ -806,8 +806,8 @@ publish_uris_set_timeout (GSList *uris) g_slist_free (uris); } -int -e_plugin_lib_enable (EPlugin *ep, int enable) +gint +e_plugin_lib_enable (EPlugin *ep, gint enable) { GSList *uris; GConfClient *client; @@ -831,7 +831,7 @@ e_plugin_lib_enable (EPlugin *ep, int enable) } struct eq_data { - char *description; + gchar *description; GError *error; }; @@ -899,7 +899,7 @@ error_queue_show_idle (gpointer user_data) } void -error_queue_add (char *description, GError *error) +error_queue_add (gchar *description, GError *error) { struct eq_data *data; diff --git a/plugins/publish-calendar/publish-format-fb.c b/plugins/publish-calendar/publish-format-fb.c index b28444458e..01b4e7a926 100644 --- a/plugins/publish-calendar/publish-format-fb.c +++ b/plugins/publish-calendar/publish-format-fb.c @@ -33,7 +33,7 @@ #include "publish-format-fb.h" static gboolean -write_calendar (gchar *uid, ESourceList *source_list, GOutputStream *stream, int dur_type, int dur_value, GError **error) +write_calendar (gchar *uid, ESourceList *source_list, GOutputStream *stream, gint dur_type, gint dur_value, GError **error) { ESource *source; ECal *client = NULL; @@ -41,7 +41,7 @@ write_calendar (gchar *uid, ESourceList *source_list, GOutputStream *stream, int icaltimezone *utc; time_t start = time(NULL), end; icalcomponent *top_level; - char *email = NULL; + gchar *email = NULL; GList *users = NULL; gboolean res = FALSE; @@ -83,7 +83,7 @@ write_calendar (gchar *uid, ESourceList *source_list, GOutputStream *stream, int top_level = e_cal_util_new_top_level (); if (e_cal_get_free_busy (client, users, start, end, &objects, error)) { - char *ical_string; + gchar *ical_string; while (objects) { ECalComponent *comp = objects->data; diff --git a/plugins/publish-calendar/publish-format-ical.c b/plugins/publish-calendar/publish-format-ical.c index 04e70ca8a8..f6e780daab 100644 --- a/plugins/publish-calendar/publish-format-ical.c +++ b/plugins/publish-calendar/publish-format-ical.c @@ -36,9 +36,9 @@ typedef struct { } CompTzData; static void -insert_tz_comps (icalparameter *param, void *cb_data) +insert_tz_comps (icalparameter *param, gpointer cb_data) { - const char *tzid; + const gchar *tzid; CompTzData *tdata = cb_data; icaltimezone *zone = NULL; icalcomponent *tzcomp; @@ -91,7 +91,7 @@ write_calendar (gchar *uid, ESourceList *source_list, GOutputStream *stream, GEr top_level = e_cal_util_new_top_level (); if (e_cal_get_object_list (client, "#t", &objects, error)) { - char *ical_string; + gchar *ical_string; CompTzData tdata; tdata.zones = g_hash_table_new (g_str_hash, g_str_equal); diff --git a/plugins/publish-calendar/publish-location.c b/plugins/publish-calendar/publish-location.c index 71b82c8e07..98a8247725 100644 --- a/plugins/publish-calendar/publish-location.c +++ b/plugins/publish-calendar/publish-location.c @@ -54,12 +54,12 @@ migrateURI (const gchar *xml, xmlDocPtr doc) uri = g_new0 (EPublishUri, 1); root = doc->children; - location = xmlGetProp (root, (const unsigned char *)"location"); - enabled = xmlGetProp (root, (const unsigned char *)"enabled"); - frequency = xmlGetProp (root, (const unsigned char *)"frequency"); - username = xmlGetProp (root, (const unsigned char *)"username"); + location = xmlGetProp (root, (const guchar *)"location"); + enabled = xmlGetProp (root, (const guchar *)"enabled"); + frequency = xmlGetProp (root, (const guchar *)"frequency"); + username = xmlGetProp (root, (const guchar *)"username"); - euri = e_uri_new ((const char *)location); + euri = e_uri_new ((const gchar *)location); if (!euri) { g_warning ("Could not form the uri for %s \n", location); @@ -69,7 +69,7 @@ migrateURI (const gchar *xml, xmlDocPtr doc) if (euri->user) g_free (euri->user); - euri->user = g_strdup ((const char *)username); + euri->user = g_strdup ((const gchar *)username); temp = e_uri_to_string (euri, FALSE); uri->location = g_strdup_printf ("dav://%s", strstr (temp, "//") + 2); @@ -77,21 +77,21 @@ migrateURI (const gchar *xml, xmlDocPtr doc) e_uri_free (euri); if (enabled != NULL) - uri->enabled = atoi ((char *)enabled); + uri->enabled = atoi ((gchar *)enabled); if (frequency != NULL) - uri->publish_frequency = atoi ((char *)frequency); + uri->publish_frequency = atoi ((gchar *)frequency); uri->publish_format = URI_PUBLISH_AS_FB; - password = e_passwords_get_password ("Calendar", (char *)location); + password = e_passwords_get_password ("Calendar", (gchar *)location); if (password) { - e_passwords_forget_password ("Calendar", (char *)location); + e_passwords_forget_password ("Calendar", (gchar *)location); e_passwords_add_password (uri->location, password); e_passwords_remember_password ("Calendar", uri->location); } for (p = root->children; p != NULL; p = p->next) { - xmlChar *uid = xmlGetProp (p, (const unsigned char *)"uid"); - if (strcmp ((char *)p->name, "source") == 0) { + xmlChar *uid = xmlGetProp (p, (const guchar *)"uid"); + if (strcmp ((gchar *)p->name, "source") == 0) { events = g_slist_append (events, uid); } else { g_free (uid); @@ -125,15 +125,15 @@ e_publish_uri_from_xml (const gchar *xml) GSList *events = NULL; EPublishUri *uri; - doc = xmlParseDoc ((const unsigned char *)xml); + doc = xmlParseDoc ((const guchar *)xml); if (doc == NULL) return NULL; root = doc->children; - if (strcmp ((char *)root->name, "uri") != 0) + if (strcmp ((gchar *)root->name, "uri") != 0) return NULL; - if ((username = xmlGetProp (root, (const unsigned char *)"username"))) { + if ((username = xmlGetProp (root, (const guchar *)"username"))) { xmlFree (username); return migrateURI (xml, doc); @@ -141,27 +141,27 @@ e_publish_uri_from_xml (const gchar *xml) uri = g_new0 (EPublishUri, 1); - location = xmlGetProp (root, (const unsigned char *)"location"); - enabled = xmlGetProp (root, (const unsigned char *)"enabled"); - frequency = xmlGetProp (root, (const unsigned char *)"frequency"); - format = xmlGetProp (root, (const unsigned char *)"format"); - publish_time = xmlGetProp (root, (const unsigned char *)"publish_time"); + location = xmlGetProp (root, (const guchar *)"location"); + enabled = xmlGetProp (root, (const guchar *)"enabled"); + frequency = xmlGetProp (root, (const guchar *)"frequency"); + format = xmlGetProp (root, (const guchar *)"format"); + publish_time = xmlGetProp (root, (const guchar *)"publish_time"); fb_duration_value = xmlGetProp (root, (xmlChar *)"fb_duration_value"); fb_duration_type = xmlGetProp (root, (xmlChar *)"fb_duration_type"); if (location != NULL) - uri->location = (char *)location; + uri->location = (gchar *)location; if (enabled != NULL) - uri->enabled = atoi ((char *)enabled); + uri->enabled = atoi ((gchar *)enabled); if (frequency != NULL) - uri->publish_frequency = atoi ((char *)frequency); + uri->publish_frequency = atoi ((gchar *)frequency); if (format != NULL) - uri->publish_format = atoi ((char *)format); + uri->publish_format = atoi ((gchar *)format); if (publish_time != NULL) - uri->last_pub_time = (char *)publish_time; + uri->last_pub_time = (gchar *)publish_time; if (fb_duration_value) - uri->fb_duration_value = atoi ((char *)fb_duration_value); + uri->fb_duration_value = atoi ((gchar *)fb_duration_value); else uri->fb_duration_value = -1; @@ -170,9 +170,9 @@ e_publish_uri_from_xml (const gchar *xml) else if (uri->fb_duration_value > 100) uri->fb_duration_value = 100; - if (fb_duration_type && g_str_equal ((char *)fb_duration_type, "days")) + if (fb_duration_type && g_str_equal ((gchar *)fb_duration_type, "days")) uri->fb_duration_type = FB_DURATION_DAYS; - else if (fb_duration_type && g_str_equal ((char *)fb_duration_type, "months")) + else if (fb_duration_type && g_str_equal ((gchar *)fb_duration_type, "months")) uri->fb_duration_type = FB_DURATION_MONTHS; else uri->fb_duration_type = FB_DURATION_WEEKS; @@ -180,8 +180,8 @@ e_publish_uri_from_xml (const gchar *xml) uri->password = g_strdup (""); for (p = root->children; p != NULL; p = p->next) { - xmlChar *uid = xmlGetProp (p, (const unsigned char *)"uid"); - if (strcmp ((char *)p->name, "event") == 0) { + xmlChar *uid = xmlGetProp (p, (const guchar *)"uid"); + if (strcmp ((gchar *)p->name, "event") == 0) { events = g_slist_append (events, uid); } else { g_free (uid); @@ -207,23 +207,23 @@ e_publish_uri_to_xml (EPublishUri *uri) gchar *enabled, *frequency, *format; GSList *calendars = NULL; xmlChar *xml_buffer; - char *returned_buffer; - int xml_buffer_size; + gchar *returned_buffer; + gint xml_buffer_size; g_return_val_if_fail (uri != NULL, NULL); g_return_val_if_fail (uri->location != NULL, NULL); - doc = xmlNewDoc ((const unsigned char *)"1.0"); + doc = xmlNewDoc ((const guchar *)"1.0"); - root = xmlNewDocNode (doc, NULL, (const unsigned char *)"uri", NULL); + root = xmlNewDocNode (doc, NULL, (const guchar *)"uri", NULL); enabled = g_strdup_printf ("%d", uri->enabled); frequency = g_strdup_printf ("%d", uri->publish_frequency); format = g_strdup_printf ("%d", uri->publish_format); - xmlSetProp (root, (const unsigned char *)"location", (unsigned char *)uri->location); - xmlSetProp (root, (const unsigned char *)"enabled", (unsigned char *)enabled); - xmlSetProp (root, (const unsigned char *)"frequency", (unsigned char *)frequency); - xmlSetProp (root, (const unsigned char *)"format", (unsigned char *)format); - xmlSetProp (root, (const unsigned char *)"publish_time", (unsigned char *)uri->last_pub_time); + xmlSetProp (root, (const guchar *)"location", (guchar *)uri->location); + xmlSetProp (root, (const guchar *)"enabled", (guchar *)enabled); + xmlSetProp (root, (const guchar *)"frequency", (guchar *)frequency); + xmlSetProp (root, (const guchar *)"format", (guchar *)format); + xmlSetProp (root, (const guchar *)"publish_time", (guchar *)uri->last_pub_time); g_free (format); format = g_strdup_printf ("%d", uri->fb_duration_value); @@ -238,8 +238,8 @@ e_publish_uri_to_xml (EPublishUri *uri) for (calendars = uri->events; calendars != NULL; calendars = g_slist_next (calendars)) { xmlNodePtr node; - node = xmlNewChild (root, NULL, (const unsigned char *)"event", NULL); - xmlSetProp (node, (const unsigned char *)"uid", calendars->data); + node = xmlNewChild (root, NULL, (const guchar *)"event", NULL); + xmlSetProp (node, (const guchar *)"uid", calendars->data); } xmlDocSetRootElement (doc, root); diff --git a/plugins/publish-calendar/publish-location.h b/plugins/publish-calendar/publish-location.h index a6afc2c272..a55d432a8e 100644 --- a/plugins/publish-calendar/publish-location.h +++ b/plugins/publish-calendar/publish-location.h @@ -34,7 +34,7 @@ enum publish_frequency { URI_PUBLISH_MANUAL }; -static const int publish_frequency_type_map[] = { +static const gint publish_frequency_type_map[] = { URI_PUBLISH_DAILY, URI_PUBLISH_WEEKLY, URI_PUBLISH_MANUAL, @@ -46,7 +46,7 @@ enum publish_format { URI_PUBLISH_AS_FB }; -static const int publish_format_type_mask[] = { +static const gint publish_format_type_mask[] = { URI_PUBLISH_AS_ICAL, URI_PUBLISH_AS_FB, -1 @@ -67,8 +67,8 @@ struct _EPublishUri { gchar *password; GSList *events; gchar *last_pub_time; - int fb_duration_value; - int fb_duration_type; + gint fb_duration_value; + gint fb_duration_type; gint service_type; }; diff --git a/plugins/publish-calendar/url-editor-dialog.c b/plugins/publish-calendar/url-editor-dialog.c index 08e59513e8..7456d4b193 100644 --- a/plugins/publish-calendar/url-editor-dialog.c +++ b/plugins/publish-calendar/url-editor-dialog.c @@ -43,7 +43,7 @@ create_uri (UrlEditorDialog *dialog) uri->location = g_strdup (gtk_entry_get_text (GTK_ENTRY (dialog->server_entry))); } else { const gchar *method; - char *server, *file, *port, *username, *password; + gchar *server, *file, *port, *username, *password; server = g_strdup (gtk_entry_get_text (GTK_ENTRY (dialog->server_entry))); file = g_strdup (gtk_entry_get_text (GTK_ENTRY (dialog->file_entry))); @@ -279,7 +279,7 @@ static void set_from_uri (UrlEditorDialog *dialog) { EPublishUri *uri; - char *method; + gchar *method; EUri *euri = NULL; uri = dialog->uri; @@ -287,17 +287,17 @@ set_from_uri (UrlEditorDialog *dialog) euri = e_uri_new (uri->location); /* determine our method */ method = euri->protocol; - if (strcmp ((const char *)method, "smb") == 0) + if (strcmp ((const gchar *)method, "smb") == 0) uri->service_type = TYPE_SMB; - else if (strcmp ((const char *)method, "sftp") == 0) + else if (strcmp ((const gchar *)method, "sftp") == 0) uri->service_type = TYPE_SFTP; - else if (strcmp ((const char *)method, "ftp") == 0) + else if (strcmp ((const gchar *)method, "ftp") == 0) /* we set TYPE_FTP here for now. if we don't find a * username later, we'll change it to TYPE_ANON_FTP */ uri->service_type = TYPE_FTP; - else if (strcmp ((const char *)method, "dav") == 0) + else if (strcmp ((const gchar *)method, "dav") == 0) uri->service_type = TYPE_DAV; - else if (strcmp ((const char *)method, "davs") == 0) + else if (strcmp ((const gchar *)method, "davs") == 0) uri->service_type = TYPE_DAVS; else uri->service_type = TYPE_URI; @@ -309,7 +309,7 @@ set_from_uri (UrlEditorDialog *dialog) gtk_entry_set_text (GTK_ENTRY (dialog->server_entry), euri->host); if (euri->port) { - char *port; + gchar *port; port = g_strdup_printf ("%d", euri->port); gtk_entry_set_text (GTK_ENTRY (dialog->port_entry), port); g_free (port); @@ -331,7 +331,7 @@ url_editor_dialog_construct (UrlEditorDialog *dialog) GConfClient *gconf; GtkSizeGroup *group; EPublishUri *uri; - char *gladefile; + gchar *gladefile; gconf = gconf_client_get_default (); diff --git a/plugins/python/python-plugin-loader.c b/plugins/python/python-plugin-loader.c index ea9ab4bfb0..4d7ead37da 100644 --- a/plugins/python/python-plugin-loader.c +++ b/plugins/python/python-plugin-loader.c @@ -28,7 +28,7 @@ #define d(x) -static void *epp_parent_class; +static gpointer epp_parent_class; typedef struct _EPluginPythonPrivate { PyObject *pModule; @@ -40,13 +40,13 @@ typedef struct _EPluginPythonPrivate { #define epp ((EPluginPython *)ep) -void * load_plugin_type_register_function (void *a, void *b); +gpointer load_plugin_type_register_function (gpointer a, gpointer b); -static char * -get_xml_prop(xmlNodePtr node, const char *id) +static gchar * +get_xml_prop(xmlNodePtr node, const gchar *id) { - char *p = xmlGetProp(node, id); - char *out = NULL; + gchar *p = xmlGetProp(node, id); + gchar *out = NULL; if (p) { out = g_strdup(p); @@ -56,8 +56,8 @@ get_xml_prop(xmlNodePtr node, const char *id) return out; } -static void * -epp_invoke(EPlugin *ep, const char *name, void *data) +static gpointer +epp_invoke(EPlugin *ep, const gchar *name, gpointer data) { EPluginPythonPrivate *p = epp->priv; PyObject *pModuleName, *pFunc; @@ -168,8 +168,8 @@ epp_init(GObject *o) (GDestroyNotify) NULL); } -void * -load_plugin_type_register_function (void *a, void *b) +gpointer +load_plugin_type_register_function (gpointer a, gpointer b) { static GType type = 0; diff --git a/plugins/python/python-plugin-loader.h b/plugins/python/python-plugin-loader.h index 4f9656e119..4f31ddd5a7 100644 --- a/plugins/python/python-plugin-loader.h +++ b/plugins/python/python-plugin-loader.h @@ -33,16 +33,16 @@ struct _EPluginPython { struct _EPluginPythonPrivate *priv; - char *location; /* location */ - char *pClass; /* handler class */ - char *module_name; + gchar *location; /* location */ + gchar *pClass; /* handler class */ + gchar *module_name; }; struct _EPluginPythonClass { EPluginClass plugin_class; }; -void *org_gnome_evolution_python_get_type(void *a, void *b); +gpointer org_gnome_evolution_python_get_type(gpointer a, gpointer b); #endif /* ! _ORG_GNOME_EVOLUTION_PYTHON_H */ diff --git a/plugins/sa-junk-plugin/em-junk-filter.c b/plugins/sa-junk-plugin/em-junk-filter.c index 8846e8b4be..3c92b386ae 100644 --- a/plugins/sa-junk-plugin/em-junk-filter.c +++ b/plugins/sa-junk-plugin/em-junk-filter.c @@ -58,12 +58,12 @@ static pthread_mutex_t em_junk_sa_report_lock = PTHREAD_MUTEX_INITIALIZER; static pthread_mutex_t em_junk_sa_preferred_socket_path_lock = PTHREAD_MUTEX_INITIALIZER; static pthread_mutex_t em_junk_sa_spamd_restart_lock = PTHREAD_MUTEX_INITIALIZER; -int e_plugin_lib_enable (EPluginLib *ep, int enable); +gint e_plugin_lib_enable (EPluginLib *ep, gint enable); gboolean em_junk_sa_check_junk (EPlugin *ep, EMJunkHookTarget *target); void em_junk_sa_report_junk (EPlugin *ep, EMJunkHookTarget *target); void em_junk_sa_report_non_junk (EPlugin *ep, EMJunkHookTarget *target); void em_junk_sa_commit_reports (EPlugin *ep); -void *em_junk_sa_validate_binary (EPlugin *ep); +gpointer em_junk_sa_validate_binary (EPlugin *ep); GtkWidget *org_gnome_sa_use_remote_tests (struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data); static void em_junk_sa_init (void); @@ -79,41 +79,41 @@ static gboolean em_junk_sa_system_spamd_available = FALSE; static gboolean em_junk_sa_new_daemon_started = FALSE; static gboolean em_junk_sa_checked_spamassassin_version = FALSE; static guint em_junk_sa_spamassassin_version = 0; -static char *em_junk_sa_socket_path = NULL; -static char *em_junk_sa_spamd_pidfile = NULL; +static gchar *em_junk_sa_socket_path = NULL; +static gchar *em_junk_sa_spamd_pidfile = NULL; static const gchar *em_junk_sa_spamc_binary = NULL; static GConfClient *em_junk_sa_gconf = NULL; /* volatile so not cached between threads */ static volatile gboolean em_junk_sa_local_only; static volatile gboolean em_junk_sa_use_daemon; -static char * em_junk_sa_preferred_socket_path; +static gchar * em_junk_sa_preferred_socket_path; static const gchar *em_junk_sa_spamc_binaries [4] = {"spamc", "/usr/bin/spamc", "/usr/sbin/spamc", NULL}; static const gchar *em_junk_sa_spamd_binaries [4] = {"spamd", "/usr/bin/spamd", "/usr/sbin/spamd", NULL}; #define SPAMD_RESTARTS_SIZE 8 static time_t em_junk_sa_spamd_restarts [SPAMD_RESTARTS_SIZE] = {0, 0, 0, 0, 0, 0, 0, 0}; -static int em_junk_sa_spamd_restarts_count = 0; +static gint em_junk_sa_spamd_restarts_count = 0; /* Variables to indicate whether spamd is running with --allow-tell */ -static int no_allow_tell; +static gint no_allow_tell; static gboolean em_junk_sa_allow_tell_tested = FALSE; -char *em_junk_sa_spamc_gconf_binary = NULL; -char *em_junk_sa_spamd_gconf_binary = NULL; +gchar *em_junk_sa_spamc_gconf_binary = NULL; +gchar *em_junk_sa_spamd_gconf_binary = NULL; static int -pipe_to_sa_full (CamelMimeMessage *msg, const gchar *in, const gchar **argv, int rv_err, int wait_for_termination, GByteArray *output_buffer, GError **error) +pipe_to_sa_full (CamelMimeMessage *msg, const gchar *in, const gchar **argv, gint rv_err, gint wait_for_termination, GByteArray *output_buffer, GError **error) { - int result, status, errnosav, fds[2], out_fds[2]; + gint result, status, errnosav, fds[2], out_fds[2]; CamelStream *stream; - char *program; + gchar *program; pid_t pid; if (camel_debug_start ("junk")) { - int i; + gint i; printf ("pipe_to_sa "); for (i = 0; argv[i]; i++) @@ -150,7 +150,7 @@ pipe_to_sa_full (CamelMimeMessage *msg, const gchar *in, const gchar **argv, int if (!(pid = fork ())) { /* child process */ - int maxfd, fd, nullfd; + gint maxfd, fd, nullfd; nullfd = open ("/dev/null", O_WRONLY); @@ -212,13 +212,13 @@ pipe_to_sa_full (CamelMimeMessage *msg, const gchar *in, const gchar **argv, int camel_stream_write_to_stream (stream, (CamelStream *) memstream); camel_object_unref (stream); - g_byte_array_append (output_buffer, (unsigned char *)"", 1); + g_byte_array_append (output_buffer, (guchar *)"", 1); d(printf ("child process output: %s len: %d\n", output_buffer->data, output_buffer->len)); } if (wait_for_termination) { - int res; + gint res; d(printf ("wait for child %d termination\n", pid)); result = waitpid (pid, &status, 0); @@ -259,7 +259,7 @@ pipe_to_sa (CamelMimeMessage *msg, const gchar *in, const gchar **argv, GError * return pipe_to_sa_full (msg, in, argv, -1, 1, NULL, error); } -static char * +static gchar * em_junk_sa_get_socket_path () { if (em_junk_sa_preferred_socket_path) @@ -272,7 +272,7 @@ static gboolean em_junk_sa_test_spamd_running (const gchar *binary, gboolean system) { const gchar *argv[5]; - int i = 0; + gint i = 0; gboolean rv; pthread_mutex_lock (&em_junk_sa_preferred_socket_path_lock); @@ -341,7 +341,7 @@ static gboolean em_junk_sa_run_spamd (const gchar *binary) { const gchar *argv[8]; - int i; + gint i; gboolean rv = FALSE; pthread_mutex_lock (&em_junk_sa_preferred_socket_path_lock); @@ -395,7 +395,7 @@ em_junk_sa_run_spamd (const gchar *binary) static void em_junk_sa_start_own_daemon () { - int b; + gint b; em_junk_sa_new_daemon_started = FALSE; @@ -415,7 +415,7 @@ static void em_junk_sa_find_spamc () { if (em_junk_sa_use_spamc && em_junk_sa_new_daemon_started) { - int b; + gint b; em_junk_sa_use_spamc = FALSE; for (b = 0; em_junk_sa_spamc_binaries [b]; b ++) { @@ -432,7 +432,7 @@ static void em_junk_sa_test_spamd (void) { const gchar *argv[4]; - int i, b; + gint i, b; gboolean try_system_spamd = TRUE; if (em_junk_sa_spamc_gconf_binary) { @@ -578,8 +578,8 @@ em_junk_sa_check_junk(EPlugin *ep, EMJunkHookTarget *target) { GByteArray *out = NULL; const gchar *argv[7]; - char *to_free = NULL; - int i = 0, socket_i; + gchar *to_free = NULL; + gint i = 0, socket_i; gboolean rv; CamelMimeMessage *msg = target->m; @@ -613,7 +613,7 @@ em_junk_sa_check_junk(EPlugin *ep, EMJunkHookTarget *target) rv = pipe_to_sa_full (msg, NULL, argv, 0, 1, out, &target->error) != 0; - if (!rv && out && out->data && !strcmp ((const char *)out->data, "0/0\n")) { + if (!rv && out && out->data && !strcmp ((const gchar *)out->data, "0/0\n")) { /* an error occurred */ if (em_junk_sa_respawn_spamd ()) { g_byte_array_set_size (out, 0); @@ -643,7 +643,7 @@ static guint get_spamassassin_version () { GByteArray *out = NULL; - int i; + gint i; const gchar *argv[3] = { "sa-learn", @@ -721,7 +721,7 @@ em_junk_sa_report_junk (EPlugin *ep, EMJunkHookTarget *target) void em_junk_sa_report_non_junk (EPlugin *ep, EMJunkHookTarget *target) { - const char *sync_op = + const gchar *sync_op = (get_spamassassin_version () >= 3) ? "--no-sync": "--no-rebuild"; const gchar *argv[6] = { @@ -783,17 +783,17 @@ em_junk_sa_commit_reports (EPlugin *ep) } } -void * +gpointer em_junk_sa_validate_binary (EPlugin *ep) { - return em_junk_sa_is_available (NULL) ? (void *) "1" : NULL; + return em_junk_sa_is_available (NULL) ? (gpointer) "1" : NULL; } static void -em_junk_sa_setting_notify(GConfClient *gconf, guint cnxn_id, GConfEntry *entry, void *data) +em_junk_sa_setting_notify(GConfClient *gconf, guint cnxn_id, GConfEntry *entry, gpointer data) { GConfValue *value; - char *tkey; + gchar *tkey; g_return_if_fail (gconf_entry_get_key (entry) != NULL); @@ -815,8 +815,8 @@ em_junk_sa_setting_notify(GConfClient *gconf, guint cnxn_id, GConfEntry *entry, } } -int -e_plugin_lib_enable (EPluginLib *ep, int enable) +gint +e_plugin_lib_enable (EPluginLib *ep, gint enable) { em_junk_sa_init(); @@ -862,15 +862,15 @@ em_junk_sa_kill_spamd (void) pthread_mutex_unlock (&em_junk_sa_preferred_socket_path_lock); if (em_junk_sa_new_daemon_started) { - int fd = open (em_junk_sa_spamd_pidfile, O_RDONLY); + gint fd = open (em_junk_sa_spamd_pidfile, O_RDONLY); if (fd != -1) { - char pid_str [16]; - int bytes; + gchar pid_str [16]; + gint bytes; bytes = read (fd, pid_str, 15); if (bytes > 0) { - int pid; + gint pid; pid_str [bytes] = 0; pid = atoi (pid_str); @@ -907,7 +907,7 @@ GtkWidget * org_gnome_sa_use_remote_tests (struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data) { GtkWidget *check, *vbox, *label; - char *text = g_strdup_printf (" <small>%s</small>", _("This will make SpamAssassin more reliable, but slower")); + gchar *text = g_strdup_printf (" <small>%s</small>", _("This will make SpamAssassin more reliable, but slower")); guint i = ((GtkTable *)data->parent)->nrows; if (data->old) diff --git a/plugins/save-calendar/csv-format.c b/plugins/save-calendar/csv-format.c index 2f9c92d6f7..4e59b80edd 100644 --- a/plugins/save-calendar/csv-format.c +++ b/plugins/save-calendar/csv-format.c @@ -47,7 +47,7 @@ struct _CsvConfig { gboolean header; }; -static gboolean string_needsquotes (const char *value, CsvConfig *config); +static gboolean string_needsquotes (const gchar *value, CsvConfig *config); typedef struct _CsvPluginData CsvPluginData; struct _CsvPluginData @@ -93,7 +93,7 @@ add_list_to_csv (GString *line, GSList *list_in, CsvConfig *config, gint type) GString *tmp = NULL; gint cnt=0; while (list) { - const char *str = NULL; + const gchar *str = NULL; if (cnt == 0) tmp = g_string_new (""); if (cnt > 0) @@ -113,7 +113,7 @@ add_list_to_csv (GString *line, GSList *list_in, CsvConfig *config, gint type) if (!needquotes) needquotes = string_needsquotes (str, config); if (str) - tmp = g_string_append (tmp, (const gchar*)str); + tmp = g_string_append (tmp, (const gchar *)str); list = g_slist_next (list); cnt++; if (list) tmp = g_string_append (tmp, config->delimiter); @@ -154,7 +154,7 @@ add_time_to_csv (GString *line, icaltimetype *time, CsvConfig *config) if (time) { gboolean needquotes = FALSE; struct tm mytm = icaltimetype_to_tm (time); - gchar *str = (gchar*) g_malloc (sizeof (gchar) * 200); + gchar *str = (gchar *) g_malloc (sizeof (gchar) * 200); /* * Translator: the %F %T is the thirth argument for a strftime function. @@ -182,7 +182,7 @@ add_time_to_csv (GString *line, icaltimetype *time, CsvConfig *config) } static gboolean -string_needsquotes (const char *value, CsvConfig *config) +string_needsquotes (const gchar *value, CsvConfig *config) { /* This is the actual need for quotes-checker */ @@ -243,7 +243,7 @@ string_needsquotes (const char *value, CsvConfig *config) } static GString * -add_string_to_csv (GString *line, const char *value, CsvConfig *config) +add_string_to_csv (GString *line, const gchar *value, CsvConfig *config) { /* Will add a string to the record and will check for the need for quotes */ @@ -252,7 +252,7 @@ add_string_to_csv (GString *line, const char *value, CsvConfig *config) if (needquotes) line = g_string_append (line, config->quote); - line = g_string_append (line, (const gchar*)value); + line = g_string_append (line, (const gchar *)value); if (needquotes) line = g_string_append (line, config->quote); } @@ -303,7 +303,7 @@ userstring_to_systemstring (const gchar *userstring) } static void -do_save_calendar_csv (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, char *dest_uri) +do_save_calendar_csv (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, gchar *dest_uri) { /* @@ -393,11 +393,11 @@ do_save_calendar_csv (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource while (objects != NULL) { ECalComponent *comp = objects->data; gchar *delimiter_temp = NULL; - const char *temp_constchar; + const gchar *temp_constchar; GSList *temp_list; ECalComponentDateTime temp_dt; struct icaltimetype *temp_time; - int *temp_int; + gint *temp_int; ECalComponentText temp_comptext; line = g_string_new (""); diff --git a/plugins/save-calendar/format-handler.h b/plugins/save-calendar/format-handler.h index a7bc2e8d85..f9e15dc771 100644 --- a/plugins/save-calendar/format-handler.h +++ b/plugins/save-calendar/format-handler.h @@ -43,11 +43,11 @@ struct _FormatHandler gpointer data; - void (*save) (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, char *dest_uri); + void (*save) (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, gchar *dest_uri); }; FormatHandler *csv_format_handler_new (void); FormatHandler *ical_format_handler_new (void); FormatHandler *rdf_format_handler_new (void); -GOutputStream *open_for_writing (GtkWindow *parent, const char *uri, GError **error); +GOutputStream *open_for_writing (GtkWindow *parent, const gchar *uri, GError **error); diff --git a/plugins/save-calendar/ical-format.c b/plugins/save-calendar/ical-format.c index f538a9e0a1..3b54176284 100644 --- a/plugins/save-calendar/ical-format.c +++ b/plugins/save-calendar/ical-format.c @@ -39,7 +39,7 @@ #include "e-util/e-error.h" static void -display_error_message (GtkWidget *parent, const char *message) +display_error_message (GtkWidget *parent, const gchar *message) { GtkWidget *dialog; @@ -54,9 +54,9 @@ typedef struct { } CompTzData; static void -insert_tz_comps (icalparameter *param, void *cb_data) +insert_tz_comps (icalparameter *param, gpointer cb_data) { - const char *tzid; + const gchar *tzid; CompTzData *tdata = cb_data; icaltimezone *zone = NULL; icalcomponent *tzcomp; @@ -84,7 +84,7 @@ append_tz_to_comp (gpointer key, gpointer value, icalcomponent *toplevel) } static void -do_save_calendar_ical (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, char *dest_uri) +do_save_calendar_ical (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, gchar *dest_uri) { ESource *primary_source; ECal *source_client; @@ -136,7 +136,7 @@ do_save_calendar_ical (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSourc stream = open_for_writing (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (target->selector))), dest_uri, &error); if (stream) { - char *ical_str = icalcomponent_as_ical_string_r (top_level); + gchar *ical_str = icalcomponent_as_ical_string_r (top_level); g_output_stream_write_all (stream, ical_str, strlen (ical_str), NULL, NULL, &error); g_output_stream_close (stream, NULL, NULL); diff --git a/plugins/save-calendar/rdf-format.c b/plugins/save-calendar/rdf-format.c index 9c9f864a2a..685fbdd6e5 100644 --- a/plugins/save-calendar/rdf-format.c +++ b/plugins/save-calendar/rdf-format.c @@ -45,7 +45,7 @@ #include "format-handler.h" static void -add_string_to_rdf (xmlNodePtr node, const gchar *tag, const char *value); +add_string_to_rdf (xmlNodePtr node, const gchar *tag, const gchar *value); /* Use { */ @@ -100,7 +100,7 @@ add_list_to_rdf (xmlNodePtr node, const gchar *tag, GSList *list_in, gint type) GSList *list = list_in; while (list) { - const char *str = NULL; + const gchar *str = NULL; switch (type) { case ECALCOMPONENTATTENDEE: @@ -127,8 +127,8 @@ add_nummeric_to_rdf (xmlNodePtr node, const gchar *tag, gint *nummeric) { if (nummeric) { gchar *value = g_strdup_printf ("%d", *nummeric); - xmlNodePtr cur_node = xmlNewChild (node, NULL, (unsigned char *)tag, (unsigned char *)value); - xmlSetProp (cur_node, (const unsigned char *)"rdf:datatype", (const unsigned char *)"http://www.w3.org/2001/XMLSchema#integer"); + xmlNodePtr cur_node = xmlNewChild (node, NULL, (guchar *)tag, (guchar *)value); + xmlSetProp (cur_node, (const guchar *)"rdf:datatype", (const guchar *)"http://www.w3.org/2001/XMLSchema#integer"); g_free (value); } } @@ -139,7 +139,7 @@ add_time_to_rdf (xmlNodePtr node, const gchar *tag, icaltimetype *time) if (time) { xmlNodePtr cur_node = NULL; struct tm mytm = icaltimetype_to_tm (time); - gchar *str = (gchar*) g_malloc (sizeof (gchar) * 200); + gchar *str = (gchar *) g_malloc (sizeof (gchar) * 200); gchar *tmp = NULL; gchar *timezone; /* @@ -149,12 +149,12 @@ add_time_to_rdf (xmlNodePtr node, const gchar *tag, icaltimetype *time) * */ e_utf8_strftime (str, 200, _("%FT%T"), &mytm); - cur_node = xmlNewChild (node, NULL, (unsigned char *)tag, (unsigned char *)str); + cur_node = xmlNewChild (node, NULL, (guchar *)tag, (guchar *)str); /* Not sure about this property */ timezone = calendar_config_get_timezone (); tmp = g_strdup_printf ("http://www.w3.org/2002/12/cal/tzd/%s#tz", timezone); - xmlSetProp (cur_node, (const unsigned char *)"rdf:datatype", (unsigned char *)tmp); + xmlSetProp (cur_node, (const guchar *)"rdf:datatype", (guchar *)tmp); g_free (tmp); g_free (timezone); g_free (str); @@ -163,12 +163,12 @@ add_time_to_rdf (xmlNodePtr node, const gchar *tag, icaltimetype *time) static void -add_string_to_rdf (xmlNodePtr node, const gchar *tag, const char *value) +add_string_to_rdf (xmlNodePtr node, const gchar *tag, const gchar *value) { if (value) { xmlNodePtr cur_node = NULL; - cur_node = xmlNewChild (node, NULL, (unsigned char *)tag, (unsigned char *)value); - xmlSetProp (cur_node, (const unsigned char *)"rdf:datatype", (const unsigned char *)"http://www.w3.org/2001/XMLSchema#string"); + cur_node = xmlNewChild (node, NULL, (guchar *)tag, (guchar *)value); + xmlSetProp (cur_node, (const guchar *)"rdf:datatype", (const guchar *)"http://www.w3.org/2001/XMLSchema#string"); } } @@ -176,7 +176,7 @@ add_string_to_rdf (xmlNodePtr node, const gchar *tag, const char *value) static void -do_save_calendar_rdf (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, char *dest_uri) +do_save_calendar_rdf (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource *target, ECalSourceType type, gchar *dest_uri) { /* @@ -216,51 +216,51 @@ do_save_calendar_rdf (FormatHandler *handler, EPlugin *ep, ECalPopupTargetSource xmlDocPtr doc = xmlNewDoc((xmlChar *) "1.0"); xmlNodePtr fnode = doc->children; - doc->children = xmlNewDocNode (doc, NULL, (const unsigned char *)"rdf:RDF", NULL); - xmlSetProp (doc->children, (const unsigned char *)"xmlns:rdf", (const unsigned char *)"http://www.w3.org/1999/02/22-rdf-syntax-ns#"); - xmlSetProp (doc->children, (const unsigned char *)"xmlns", (const unsigned char *)"http://www.w3.org/2002/12/cal/ical#"); + doc->children = xmlNewDocNode (doc, NULL, (const guchar *)"rdf:RDF", NULL); + xmlSetProp (doc->children, (const guchar *)"xmlns:rdf", (const guchar *)"http://www.w3.org/1999/02/22-rdf-syntax-ns#"); + xmlSetProp (doc->children, (const guchar *)"xmlns", (const guchar *)"http://www.w3.org/2002/12/cal/ical#"); - fnode = xmlNewChild (doc->children, NULL, (const unsigned char *)"Vcalendar", NULL); + fnode = xmlNewChild (doc->children, NULL, (const guchar *)"Vcalendar", NULL); /* Should Evolution publicise these? */ - xmlSetProp (fnode, (const unsigned char *)"xmlns:x-wr", (const unsigned char *)"http://www.w3.org/2002/12/cal/prod/Apple_Comp_628d9d8459c556fa#"); - xmlSetProp (fnode, (const unsigned char *)"xmlns:x-lic", (const unsigned char *)"http://www.w3.org/2002/12/cal/prod/Apple_Comp_628d9d8459c556fa#"); + xmlSetProp (fnode, (const guchar *)"xmlns:x-wr", (const guchar *)"http://www.w3.org/2002/12/cal/prod/Apple_Comp_628d9d8459c556fa#"); + xmlSetProp (fnode, (const guchar *)"xmlns:x-lic", (const guchar *)"http://www.w3.org/2002/12/cal/prod/Apple_Comp_628d9d8459c556fa#"); /* Not sure if it's correct like this */ - xmlNewChild (fnode, NULL, (const unsigned char *)"prodid", (const unsigned char *)"-//" PACKAGE_STRING "//iCal 1.0//EN"); + xmlNewChild (fnode, NULL, (const guchar *)"prodid", (const guchar *)"-//" PACKAGE_STRING "//iCal 1.0//EN"); /* Assuming GREGORIAN is the only supported calendar scale */ - xmlNewChild (fnode, NULL, (const unsigned char *)"calscale", (const unsigned char *)"GREGORIAN"); + xmlNewChild (fnode, NULL, (const guchar *)"calscale", (const guchar *)"GREGORIAN"); temp = calendar_config_get_timezone (); - xmlNewChild (fnode, NULL, (const unsigned char *)"x-wr:timezone", (unsigned char *)temp); + xmlNewChild (fnode, NULL, (const guchar *)"x-wr:timezone", (guchar *)temp); g_free (temp); - xmlNewChild (fnode, NULL, (const unsigned char *)"method", (const unsigned char *)"PUBLISH"); + xmlNewChild (fnode, NULL, (const guchar *)"method", (const guchar *)"PUBLISH"); - xmlNewChild (fnode, NULL, (const unsigned char *)"x-wr:relcalid", (unsigned char *)e_source_peek_uid (primary_source)); + xmlNewChild (fnode, NULL, (const guchar *)"x-wr:relcalid", (guchar *)e_source_peek_uid (primary_source)); - xmlNewChild (fnode, NULL, (const unsigned char *)"x-wr:calname", (unsigned char *)e_source_peek_name (primary_source)); + xmlNewChild (fnode, NULL, (const guchar *)"x-wr:calname", (guchar *)e_source_peek_name (primary_source)); /* Version of this RDF-format */ - xmlNewChild (fnode, NULL, (const unsigned char *)"version", (const unsigned char *)"2.0"); + xmlNewChild (fnode, NULL, (const guchar *)"version", (const guchar *)"2.0"); while (objects != NULL) { ECalComponent *comp = objects->data; - const char *temp_constchar; + const gchar *temp_constchar; gchar *tmp_str = NULL; GSList *temp_list; ECalComponentDateTime temp_dt; struct icaltimetype *temp_time; - int *temp_int; + gint *temp_int; ECalComponentText temp_comptext; - xmlNodePtr c_node = xmlNewChild (fnode, NULL, (const unsigned char *)"component", NULL); - xmlNodePtr node = xmlNewChild (c_node, NULL, (const unsigned char *)"Vevent", NULL); + xmlNodePtr c_node = xmlNewChild (fnode, NULL, (const guchar *)"component", NULL); + xmlNodePtr node = xmlNewChild (c_node, NULL, (const guchar *)"Vevent", NULL); /* Getting the stuff */ e_cal_component_get_uid (comp, &temp_constchar); tmp_str = g_strdup_printf ("#%s", temp_constchar); - xmlSetProp (node, (const unsigned char *)"about", (unsigned char *)tmp_str); + xmlSetProp (node, (const guchar *)"about", (guchar *)tmp_str); g_free (tmp_str); add_string_to_rdf (node, "uid",temp_constchar); diff --git a/plugins/save-calendar/save-calendar.c b/plugins/save-calendar/save-calendar.c index e461821242..c63c1dab2b 100644 --- a/plugins/save-calendar/save-calendar.c +++ b/plugins/save-calendar/save-calendar.c @@ -109,7 +109,7 @@ ask_destination_and_save (EPlugin *ep, ECalPopupTargetSource *target, ECalSource GtkListStore *store = GTK_LIST_STORE (model); GtkTreeIter iter; GtkWidget *dialog = NULL; - char *dest_uri = NULL; + gchar *dest_uri = NULL; GList *format_handlers = NULL; @@ -173,7 +173,7 @@ ask_destination_and_save (EPlugin *ep, ECalPopupTargetSource *target, ECalSource if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_OK) { - char *tmp = NULL; + gchar *tmp = NULL; gtk_combo_box_get_active_iter (combo, &iter); gtk_tree_model_get (model, &iter, @@ -186,7 +186,7 @@ ask_destination_and_save (EPlugin *ep, ECalPopupTargetSource *target, ECalSource if (!(tmp && *(tmp + strlen (handler->filename_ext)) == '\0')) { - char *temp; + gchar *temp; temp = g_strconcat (dest_uri, handler->filename_ext, NULL); g_free (dest_uri); dest_uri = temp; @@ -210,7 +210,7 @@ ask_destination_and_save (EPlugin *ep, ECalPopupTargetSource *target, ECalSource It will ask for overwrite if file already exists. */ GOutputStream * -open_for_writing (GtkWindow *parent, const char *uri, GError **error) +open_for_writing (GtkWindow *parent, const gchar *uri, GError **error) { GFile *file; GFileOutputStream *fostream; diff --git a/plugins/startup-wizard/startup-wizard.c b/plugins/startup-wizard/startup-wizard.c index 71fb4d4ff1..cc8168159b 100644 --- a/plugins/startup-wizard/startup-wizard.c +++ b/plugins/startup-wizard/startup-wizard.c @@ -101,7 +101,7 @@ startup_wizard_importer_page (EPlugin *ep, EConfigHookItemFactoryData *hook_data { GtkWidget *page, *label, *sep, *table; GSList *l; - int row=0; + gint row=0; if (import == NULL) { import = e_import_new("org.gnome.evolution.shell.importer"); @@ -123,7 +123,7 @@ startup_wizard_importer_page (EPlugin *ep, EConfigHookItemFactoryData *hook_data table = gtk_table_new(g_slist_length(import_importers), 2, FALSE); for (l = import_importers; l; l = l->next) { EImportImporter *eii = l->data; - char *str; + gchar *str; /* *label already declared */ GtkWidget *w, *label; @@ -150,21 +150,21 @@ startup_wizard_importer_page (EPlugin *ep, EConfigHookItemFactoryData *hook_data } static void -import_status(EImport *import, const char *what, int pc, void *d) +import_status(EImport *import, const gchar *what, gint pc, gpointer d) { gtk_progress_bar_set_fraction((GtkProgressBar *)import_progress, (gfloat)(pc/100.0)); gtk_progress_bar_set_text((GtkProgressBar *)import_progress, what); } static void -import_dialog_response(GtkDialog *d, guint button, void *data) +import_dialog_response(GtkDialog *d, guint button, gpointer data) { if (button == GTK_RESPONSE_CANCEL) e_import_cancel(import, (EImportTarget *)import_target, import_importer); } static void -import_done(EImport *ei, void *d) +import_done(EImport *ei, gpointer d) { if (import_iterator && (import_iterator = import_iterator->next)) { import_status(ei, "", 0, NULL); @@ -188,7 +188,7 @@ import_done(EImport *ei, void *d) void startup_wizard_commit (EPlugin *ep, EMConfigTargetAccount *target) { - char *location; + gchar *location; /* Use System Timezone by default */ calendar_config_set_use_system_timezone (TRUE); diff --git a/plugins/templates/templates.c b/plugins/templates/templates.c index a871399754..b0de28ad49 100644 --- a/plugins/templates/templates.c +++ b/plugins/templates/templates.c @@ -68,11 +68,11 @@ typedef struct { EMPopupTargetSelect *t; } UserData; -static char* get_content (CamelMimeMessage *message); +static gchar * get_content (CamelMimeMessage *message); -static void reply_with_template (EPopup *ep, EPopupItem *item, void *data); +static void reply_with_template (EPopup *ep, EPopupItem *item, gpointer data); -static void popup_free (EPopup *ep, GSList *l, void *data); +static void popup_free (EPopup *ep, GSList *l, gpointer data); static GSList *fill_submenu (CamelStore *store, CamelFolderInfo *info, @@ -143,8 +143,8 @@ commit_changes (UIData *ui) valid = gtk_tree_model_get_iter_first (model, &iter); while (valid) { - char *keyword, *value; - char *key; + gchar *keyword, *value; + gchar *key; gtk_tree_model_get (model, &iter, CLUE_KEYWORD_COLUMN, &keyword, -1); gtk_tree_model_get (model, &iter, CLUE_VALUE_COLUMN, &value, -1); @@ -168,7 +168,7 @@ static void clue_check_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *iter, UIData *ui) { GtkTreeSelection *selection; - char *keyword = NULL; + gchar *keyword = NULL; gboolean valid; selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (ui->treeview)); @@ -201,7 +201,7 @@ clue_foreach_check_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIter valid = gtk_tree_model_get_iter_first (model, iter); while (valid && gtk_list_store_iter_is_valid (ui->store, iter)) { - char *keyword = NULL; + gchar *keyword = NULL; gtk_tree_model_get (model, iter, CLUE_KEYWORD_COLUMN, &keyword, -1); /* Check if the keyword is not empty and then emit the row-changed signal (if we delete the row, then the iter gets corrupted) */ @@ -223,7 +223,7 @@ key_cell_edited_callback (GtkCellRendererText *cell, { GtkTreeModel *model; GtkTreeIter iter; - char *value; + gchar *value; model = gtk_tree_view_get_model (GTK_TREE_VIEW (ui->treeview)); @@ -244,7 +244,7 @@ value_cell_edited_callback (GtkCellRendererText *cell, { GtkTreeModel *model; GtkTreeIter iter; - char *keyword; + gchar *keyword; model = gtk_tree_view_get_model (GTK_TREE_VIEW (ui->treeview)); @@ -370,7 +370,7 @@ e_plugin_lib_get_configure_widget (EPlugin *epl) UIData *ui = g_new0 (UIData, 1); - char *gladefile; + gchar *gladefile; gladefile = g_build_filename (EVOLUTION_PLUGINDIR, "templates.glade", @@ -421,7 +421,7 @@ e_plugin_lib_get_configure_widget (EPlugin *epl) clue_list = gconf_client_get_list ( gconf, GCONF_KEY_TEMPLATE_PLACEHOLDERS, GCONF_VALUE_STRING, NULL ); for (list = clue_list; list; list = g_slist_next (list)) { - char **temp = g_strsplit (list->data, "=", 2); + gchar **temp = g_strsplit (list->data, "=", 2); gtk_list_store_append (ui->store, &iter); gtk_list_store_set (ui->store, &iter, CLUE_KEYWORD_COLUMN, temp[0], CLUE_VALUE_COLUMN, temp[1], -1); g_strfreev(temp); @@ -445,14 +445,14 @@ e_plugin_lib_get_configure_widget (EPlugin *epl) } /* borrowed from plugins/mail-to-task/ */ -static char * +static gchar * get_content (CamelMimeMessage *message) { CamelDataWrapper *content; CamelStream *mem; CamelContentType *type; CamelMimePart *mime_part = CAMEL_MIME_PART (message); - char *str, *convert_str = NULL; + gchar *str, *convert_str = NULL; gsize bytes_read, bytes_written; gint count = 2; @@ -477,7 +477,7 @@ get_content (CamelMimeMessage *message) mem = camel_stream_mem_new (); camel_data_wrapper_decode_to_stream (content, mem); - str = g_strndup ((const gchar*)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len); + str = g_strndup ((const gchar *)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len); camel_object_unref (mem); /* convert to UTF-8 string */ @@ -497,13 +497,13 @@ get_content (CamelMimeMessage *message) } static void -reply_with_template (EPopup *ep, EPopupItem *item, void *data) +reply_with_template (EPopup *ep, EPopupItem *item, gpointer data) { CamelMimeMessage *new, *template, *reply_to; CamelFolder *templates_folder; struct _camel_header_raw *header; UserData *userdata = item->user_data; - char *cont; + gchar *cont; /* We get the templates folder and all the uids of the messages in there */ templates_folder = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_TEMPLATES); @@ -559,7 +559,7 @@ reply_with_template (EPopup *ep, EPopupItem *item, void *data) } static void -popup_free (EPopup *ep, GSList *l, void *data) +popup_free (EPopup *ep, GSList *l, gpointer data) { g_slist_free (l); } @@ -567,15 +567,15 @@ popup_free (EPopup *ep, GSList *l, void *data) static GSList *append_to_menu (CamelFolder *folder, GPtrArray *uids, GSList *list, EMPopupTargetSelect *t) { - int i; + gint i; for (i = 0; i < uids->len; i++) { - const char *subject; - char *path; + const gchar *subject; + gchar *path; EPopupItem *item; CamelMimeMessage *message; UserData *user_data; - const char *uid; + const gchar *uid; uid = g_strdup (g_ptr_array_index (uids, i)); diff --git a/plugins/tnef-attachments/tnef-plugin.c b/plugins/tnef-attachments/tnef-plugin.c index ae0dc378da..cdbdb09872 100644 --- a/plugins/tnef-attachments/tnef-plugin.c +++ b/plugins/tnef-attachments/tnef-plugin.c @@ -52,42 +52,42 @@ #include <e-util/e-error.h> #include <e-util/e-mktemp.h> -int verbose = 0; -int saveRTF = 0; -int saveintermediate = 0; -char *filepath = NULL; +gint verbose = 0; +gint saveRTF = 0; +gint saveintermediate = 0; +gchar *filepath = NULL; gboolean loaded = FALSE; void processTnef(TNEFStruct *tnef); void saveVCalendar(TNEFStruct *tnef); void saveVCard(TNEFStruct *tnef); void saveVTask(TNEFStruct *tnef); -void org_gnome_format_tnef(void *ep, EMFormatHookTarget *t); +void org_gnome_format_tnef(gpointer ep, EMFormatHookTarget *t); /* Other Prototypes */ -void fprintProperty(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, char text[]); -void fprintUserProp(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, char text[]); +void fprintProperty(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, gchar text[]); +void fprintUserProp(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, gchar text[]); void quotedfprint(FILE *fptr, variableLength *vl); void cstylefprint(FILE *fptr, variableLength *vl); void printRtf(FILE *fptr, variableLength *vl); -void printRrule(FILE *fptr, char *recur_data, int size, TNEFStruct *tnef); -unsigned char getRruleCount(unsigned char a, unsigned char b); -unsigned char getRruleMonthNum(unsigned char a, unsigned char b); -char * getRruleDayname(unsigned char a); +void printRrule(FILE *fptr, gchar *recur_data, gint size, TNEFStruct *tnef); +guchar getRruleCount(guchar a, guchar b); +guchar getRruleMonthNum(guchar a, guchar b); +gchar * getRruleDayname(guchar a); void -org_gnome_format_tnef(void *ep, EMFormatHookTarget *t) +org_gnome_format_tnef(gpointer ep, EMFormatHookTarget *t) { - char *tmpdir = NULL, *name = NULL; + gchar *tmpdir = NULL, *name = NULL; CamelStream *out; struct dirent *d; DIR *dir; CamelMultipart *mp; CamelMimePart *mainpart; CamelDataWrapper *content; - int len; + gint len; TNEFStruct *tnef; tnef = (TNEFStruct *) g_malloc(sizeof(TNEFStruct)); @@ -139,8 +139,8 @@ org_gnome_format_tnef(void *ep, EMFormatHookTarget *t) CamelMimePart *part; CamelDataWrapper *content; CamelStream *stream; - char *path; - const char *type; + gchar *path; + const gchar *type; if (!strcmp(d->d_name, ".") || !strcmp(d->d_name, "..") @@ -195,10 +195,10 @@ org_gnome_format_tnef(void *ep, EMFormatHookTarget *t) } -int e_plugin_lib_enable(EPluginLib *ep, int enable); +gint e_plugin_lib_enable(EPluginLib *ep, gint enable); -int -e_plugin_lib_enable(EPluginLib *ep, int enable) +gint +e_plugin_lib_enable(EPluginLib *ep, gint enable) { if (loaded) return 0; @@ -216,14 +216,14 @@ void processTnef(TNEFStruct *tnef) { variableLength *filename; variableLength *filedata; Attachment *p; - int RealAttachment; - int object; - char * ifilename; - int i, count; - int foundCal=0; + gint RealAttachment; + gint object; + gchar * ifilename; + gint i, count; + gint foundCal=0; FILE *fptr; - ifilename = (char *) g_malloc(sizeof(char) * 256); + ifilename = (gchar *) g_malloc(sizeof(char) * 256); /* First see if this requires special processing. */ /* ie: it's a Contact Card, Task, or Meeting request (vCal/vCard) */ @@ -361,7 +361,7 @@ void processTnef(TNEFStruct *tnef) { if (filename->size == 1) { filename = (variableLength*)malloc(sizeof(variableLength)); filename->size = 20; - filename->data = (char*)malloc(20); + filename->data = (gchar *)malloc(20); sprintf(filename->data, "file_%03i.dat", count); } if (filepath == NULL) { @@ -398,12 +398,12 @@ void processTnef(TNEFStruct *tnef) { } void saveVCard(TNEFStruct *tnef) { - char ifilename[512]; + gchar ifilename[512]; FILE *fptr; variableLength *vl; variableLength *pobox, *street, *city, *state, *zip, *country; dtr thedate; - int boolean, i; + gint boolean, i; if ((vl = MAPIFindProperty(&(tnef->MapiProperties), PROP_TAG(PT_STRING8, PR_DISPLAY_NAME))) == MAPI_UNDEFINED) { if ((vl=MAPIFindProperty(&(tnef->MapiProperties), PROP_TAG(PT_STRING8, PR_COMPANY_NAME))) == MAPI_UNDEFINED) { @@ -699,11 +699,11 @@ void saveVCard(TNEFStruct *tnef) { } } -unsigned char getRruleCount(unsigned char a, unsigned char b) { +guchar getRruleCount(guchar a, guchar b) { return ((a << 8) | b); } -unsigned char getRruleMonthNum(unsigned char a, unsigned char b) { +guchar getRruleMonthNum(guchar a, guchar b) { switch (a) { case 0x00: switch (b) { @@ -773,8 +773,8 @@ unsigned char getRruleMonthNum(unsigned char a, unsigned char b) { return(0); } -char * getRruleDayname(unsigned char a) { - static char daystring[25]; +gchar * getRruleDayname(guchar a) { + static gchar daystring[25]; *daystring = 0; @@ -807,7 +807,7 @@ char * getRruleDayname(unsigned char a) { return(daystring); } -void printRrule(FILE *fptr, char *recur_data, int size, TNEFStruct *tnef) +void printRrule(FILE *fptr, gchar *recur_data, gint size, TNEFStruct *tnef) { variableLength *filename; @@ -882,11 +882,11 @@ void printRrule(FILE *fptr, char *recur_data, int size, TNEFStruct *tnef) } void saveVCalendar(TNEFStruct *tnef) { - char ifilename[256]; + gchar ifilename[256]; variableLength *filename; - char *charptr, *charptr2; + gchar *charptr, *charptr2; FILE *fptr; - int index; + gint index; DDWORD *ddword_ptr; DDWORD ddword_val; dtr thedate; @@ -1141,9 +1141,9 @@ void saveVCalendar(TNEFStruct *tnef) { void saveVTask(TNEFStruct *tnef) { variableLength *vl; variableLength *filename; - int index,i; - char ifilename[256]; - char *charptr, *charptr2; + gint index,i; + gchar ifilename[256]; + gchar *charptr, *charptr2; dtr thedate; FILE *fptr; DDWORD *ddword_ptr; @@ -1267,7 +1267,7 @@ void saveVTask(TNEFStruct *tnef) { } -void fprintProperty(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, char text[]) { +void fprintProperty(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, gchar text[]) { variableLength *vl; if ((vl=MAPIFindProperty(&(tnef->MapiProperties), PROP_TAG(proptype, propid))) != MAPI_UNDEFINED) { if (vl->size > 0) { @@ -1279,7 +1279,7 @@ void fprintProperty(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, } } -void fprintUserProp(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, char text[]) { +void fprintUserProp(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, gchar text[]) { variableLength *vl; if ((vl=MAPIFindUserProp(&(tnef->MapiProperties), PROP_TAG(proptype, propid))) != MAPI_UNDEFINED) { if (vl->size > 0) { @@ -1292,7 +1292,7 @@ void fprintUserProp(TNEFStruct *tnef, FILE *fptr, DWORD proptype, DWORD propid, } void quotedfprint(FILE *fptr, variableLength *vl) { - int index; + gint index; for (index=0;index<vl->size-1; index++) { if (vl->data[index] == '\n') { @@ -1305,7 +1305,7 @@ void quotedfprint(FILE *fptr, variableLength *vl) { } void cstylefprint(FILE *fptr, variableLength *vl) { - int index; + gint index; for (index=0;index<vl->size-1; index++) { if (vl->data[index] == '\n') { @@ -1325,10 +1325,10 @@ void cstylefprint(FILE *fptr, variableLength *vl) { } void printRtf(FILE *fptr, variableLength *vl) { - int index; - char *byte; - int brace_ct; - int key; + gint index; + gchar *byte; + gint brace_ct; + gint key; key = 0; brace_ct = 0; diff --git a/plugins/vcard-inline/vcard-inline.c b/plugins/vcard-inline/vcard-inline.c index fa0077f807..916774b4f0 100644 --- a/plugins/vcard-inline/vcard-inline.c +++ b/plugins/vcard-inline/vcard-inline.c @@ -52,7 +52,7 @@ struct _VCardInlinePObject { static gint org_gnome_vcard_inline_classid; /* Forward Declarations */ -void org_gnome_vcard_inline_format (void *ep, EMFormatHookTarget *target); +void org_gnome_vcard_inline_format (gpointer ep, EMFormatHookTarget *target); static void org_gnome_vcard_inline_pobject_free (EMFormatHTMLPObject *object) @@ -258,7 +258,7 @@ org_gnome_vcard_inline_embed (EMFormatHTML *format, } void -org_gnome_vcard_inline_format (void *ep, EMFormatHookTarget *target) +org_gnome_vcard_inline_format (gpointer ep, EMFormatHookTarget *target) { VCardInlinePObject *vcard_object; gchar *classid; diff --git a/plugins/webdav-account-setup/webdav-contacts-source.c b/plugins/webdav-account-setup/webdav-contacts-source.c index 79d4744c56..d338094726 100644 --- a/plugins/webdav-account-setup/webdav-contacts-source.c +++ b/plugins/webdav-account-setup/webdav-contacts-source.c @@ -51,8 +51,8 @@ typedef struct { GtkWidget * plugin_webdav_contacts(EPlugin *epl, EConfigHookItemFactoryData *data); -int -e_plugin_lib_enable(EPluginLib *ep, int enable); +gint +e_plugin_lib_enable(EPluginLib *ep, gint enable); static void ensure_webdav_contacts_source_group(void) @@ -136,10 +136,10 @@ static void set_ui_from_source(ui_data *data) { ESource *source = data->source; - const char *url = e_source_get_uri(source); + const gchar *url = e_source_get_uri(source); EUri *uri = e_uri_new(url); - char *url_ui; - const char *property; + gchar *url_ui; + const gchar *property; gboolean use_ssl; gboolean avoid_ifmatch; @@ -183,9 +183,9 @@ set_source_from_ui(ui_data *data) { ESource *source = data->source; gboolean avoid_ifmatch = gtk_toggle_button_get_active(data->avoid_ifmatch_toggle); - const char *url = gtk_entry_get_text(data->url_entry); + const gchar *url = gtk_entry_get_text(data->url_entry); EUri *uri = e_uri_new(url); - char *url_noprotocol; + gchar *url_noprotocol; gboolean use_ssl; e_source_set_property(source, "avoid_ifmatch", avoid_ifmatch ? "1" : "0"); @@ -247,7 +247,7 @@ plugin_webdav_contacts(EPlugin *epl, EConfigHookItemFactoryData *data) EABConfigTargetSource *t = (EABConfigTargetSource *) data->target; ESource *source; ESourceGroup *group; - const char *base_uri; + const gchar *base_uri; GtkWidget *parent; GtkWidget *vbox; @@ -342,8 +342,8 @@ plugin_webdav_contacts(EPlugin *epl, EConfigHookItemFactoryData *data) return NULL; } -int -e_plugin_lib_enable(EPluginLib *ep, int enable) +gint +e_plugin_lib_enable(EPluginLib *ep, gint enable) { if (enable) { ensure_webdav_contacts_source_group(); |