aboutsummaryrefslogtreecommitdiffstats
path: root/calendar
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2008-05-23 01:27:48 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2008-05-23 01:27:48 +0800
commite99e12428d46db3be2878f6c2ca63bd7510149f4 (patch)
treef3e50bd91132262198bea8761f84913a232790bd /calendar
parente1d0bcf694c806af75cb4d9683d1941d9721a1f9 (diff)
downloadgsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.tar.gz
gsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.tar.zst
gsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.zip
** Fixes bug #534360
2008-05-22 Matthew Barnes <mbarnes@redhat.com> ** Fixes bug #534360 Migrate from deprecated GtkObject symbols to GObject equivalents. Touches over 150 files in all components; too many to list. svn path=/trunk/; revision=35526
Diffstat (limited to 'calendar')
-rw-r--r--calendar/ChangeLog78
-rw-r--r--calendar/conduits/calendar/calendar-conduit.c44
-rw-r--r--calendar/conduits/memo/memo-conduit.c44
-rw-r--r--calendar/conduits/todo/todo-conduit.c44
-rw-r--r--calendar/gui/cal-search-bar.c36
-rw-r--r--calendar/gui/cal-search-bar.h10
-rw-r--r--calendar/gui/calendar-commands.c10
-rw-r--r--calendar/gui/calendar-view-factory.h10
-rw-r--r--calendar/gui/calendar-view.h10
-rw-r--r--calendar/gui/comp-editor-factory.h10
-rw-r--r--calendar/gui/dialogs/comp-editor-page.c107
-rw-r--r--calendar/gui/dialogs/comp-editor-page.h6
-rw-r--r--calendar/gui/dialogs/comp-editor.h2
-rw-r--r--calendar/gui/dialogs/e-delegate-dialog.h2
-rw-r--r--calendar/gui/dialogs/event-editor.h2
-rw-r--r--calendar/gui/dialogs/event-page.h2
-rw-r--r--calendar/gui/dialogs/memo-editor.h2
-rw-r--r--calendar/gui/dialogs/memo-page.h2
-rw-r--r--calendar/gui/dialogs/recurrence-page.c10
-rw-r--r--calendar/gui/dialogs/recurrence-page.h2
-rw-r--r--calendar/gui/dialogs/schedule-page.h2
-rw-r--r--calendar/gui/dialogs/task-details-page.h2
-rw-r--r--calendar/gui/dialogs/task-editor.h2
-rw-r--r--calendar/gui/dialogs/task-page.h2
-rw-r--r--calendar/gui/e-alarm-list.c2
-rw-r--r--calendar/gui/e-alarm-list.h12
-rw-r--r--calendar/gui/e-cal-component-memo-preview.h10
-rw-r--r--calendar/gui/e-cal-component-preview.h10
-rw-r--r--calendar/gui/e-cal-list-view-config.h6
-rw-r--r--calendar/gui/e-cal-list-view.h8
-rw-r--r--calendar/gui/e-calendar-table-config.h6
-rw-r--r--calendar/gui/e-calendar-table.h8
-rw-r--r--calendar/gui/e-calendar-view.h6
-rw-r--r--calendar/gui/e-cell-date-edit-config.h6
-rw-r--r--calendar/gui/e-cell-date-edit-text.h10
-rw-r--r--calendar/gui/e-date-edit-config.h6
-rw-r--r--calendar/gui/e-date-time-list.c2
-rw-r--r--calendar/gui/e-date-time-list.h12
-rw-r--r--calendar/gui/e-day-view-config.h6
-rw-r--r--calendar/gui/e-day-view-main-item.c56
-rw-r--r--calendar/gui/e-day-view-main-item.h8
-rw-r--r--calendar/gui/e-day-view-time-item.c61
-rw-r--r--calendar/gui/e-day-view-time-item.h8
-rw-r--r--calendar/gui/e-day-view-top-item.c83
-rw-r--r--calendar/gui/e-day-view-top-item.h8
-rw-r--r--calendar/gui/e-day-view.c14
-rw-r--r--calendar/gui/e-day-view.h8
-rw-r--r--calendar/gui/e-itip-control.h10
-rw-r--r--calendar/gui/e-meeting-time-sel-item.c75
-rw-r--r--calendar/gui/e-meeting-time-sel-item.h8
-rw-r--r--calendar/gui/e-meeting-time-sel.c37
-rw-r--r--calendar/gui/e-meeting-time-sel.h8
-rw-r--r--calendar/gui/e-memo-table-config.h6
-rw-r--r--calendar/gui/e-memo-table.h8
-rw-r--r--calendar/gui/e-memos.c28
-rw-r--r--calendar/gui/e-memos.h10
-rw-r--r--calendar/gui/e-mini-calendar-config.h6
-rw-r--r--calendar/gui/e-tasks.c28
-rw-r--r--calendar/gui/e-tasks.h10
-rw-r--r--calendar/gui/e-timezone-entry.c17
-rw-r--r--calendar/gui/e-timezone-entry.h8
-rw-r--r--calendar/gui/e-week-view-config.h6
-rw-r--r--calendar/gui/e-week-view-event-item.c98
-rw-r--r--calendar/gui/e-week-view-event-item.h8
-rw-r--r--calendar/gui/e-week-view-main-item.c55
-rw-r--r--calendar/gui/e-week-view-main-item.h8
-rw-r--r--calendar/gui/e-week-view-titles-item.c59
-rw-r--r--calendar/gui/e-week-view-titles-item.h8
-rw-r--r--calendar/gui/e-week-view.c17
-rw-r--r--calendar/gui/e-week-view.h8
-rw-r--r--calendar/gui/gnome-cal.c120
-rw-r--r--calendar/gui/gnome-cal.h10
-rw-r--r--calendar/gui/weekday-picker.c13
-rw-r--r--calendar/gui/weekday-picker.h10
74 files changed, 813 insertions, 663 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog
index cfd1657764..e6cf38cca7 100644
--- a/calendar/ChangeLog
+++ b/calendar/ChangeLog
@@ -1,3 +1,81 @@
+2008-05-22 Matthew Barnes <mbarnes@redhat.com>
+
+ ** Fixes part of bug #534360
+
+ * conduits/calendar/calendar-conduit.c:
+ * conduits/memo/memo-conduit.c:
+ * conduits/todo/todo-conduit.c:
+ * gui/cal-search-bar.c:
+ * gui/cal-search-bar.h:
+ * gui/calendar-commands.c:
+ * gui/calendar-view-factory.h:
+ * gui/calendar-view.h:
+ * gui/comp-editor-factory.h:
+ * gui/dialogs/comp-editor-page.c:
+ * gui/dialogs/comp-editor-page.h:
+ * gui/dialogs/comp-editor.h:
+ * gui/dialogs/e-delegate-dialog.h:
+ * gui/dialogs/event-editor.h:
+ * gui/dialogs/event-page.h:
+ * gui/dialogs/memo-editor.h:
+ * gui/dialogs/memo-page.h:
+ * gui/dialogs/recurrence-page.c:
+ * gui/dialogs/recurrence-page.h:
+ * gui/dialogs/schedule-page.h:
+ * gui/dialogs/task-details-page.h:
+ * gui/dialogs/task-editor.h:
+ * gui/dialogs/task-page.h:
+ * gui/e-alarm-list.c:
+ * gui/e-alarm-list.h:
+ * gui/e-cal-component-memo-preview.h:
+ * gui/e-cal-component-preview.h:
+ * gui/e-cal-list-view-config.h:
+ * gui/e-cal-list-view.h:
+ * gui/e-calendar-table-config.h:
+ * gui/e-calendar-table.h:
+ * gui/e-cell-date-edit-config.h:
+ * gui/e-cell-date-edit-text.h:
+ * gui/e-date-edit-config.h:
+ * gui/e-date-time-list.c:
+ * gui/e-date-time-list.h:
+ * gui/e-day-view-config.h:
+ * gui/e-day-view-main-item.c:
+ * gui/e-day-view-main-item.h:
+ * gui/e-day-view-time-item.c:
+ * gui/e-day-view-time-item.h:
+ * gui/e-day-view-top-item.c:
+ * gui/e-day-view-top-item.h:
+ * gui/e-day-view.c:
+ * gui/e-day-view.h:
+ * gui/e-itip-control.h:
+ * gui/e-meeting-time-sel-item.c:
+ * gui/e-meeting-time-sel-item.h:
+ * gui/e-meeting-time-sel.c:
+ * gui/e-meeting-time-sel.h:
+ * gui/e-memo-table-config.h:
+ * gui/e-memo-table.h:
+ * gui/e-memos.c:
+ * gui/e-memos.h:
+ * gui/e-mini-calendar-config.h:
+ * gui/e-tasks.c:
+ * gui/e-tasks.h:
+ * gui/e-timezone-entry.c:
+ * gui/e-timezone-entry.h:
+ * gui/e-week-view-config.h:
+ * gui/e-week-view-event-item.c:
+ * gui/e-week-view-event-item.h:
+ * gui/e-week-view-main-item.c:
+ * gui/e-week-view-main-item.h:
+ * gui/e-week-view-titles-item.c:
+ * gui/e-week-view-titles-item.h:
+ * gui/e-week-view.c:
+ * gui/e-week-view.h:
+ * gui/gnome-cal.c:
+ * gui/gnome-cal.h:
+ * gui/weekday-picker.c:
+ * gui/weekday-picker.h:
+ Migrate from deprecated GtkObject symbols to GObject equivalents.
+
2008-05-22 Chenthill Palanisamy <pchenthill@novell.com>
** Fix for bug #533820
diff --git a/calendar/conduits/calendar/calendar-conduit.c b/calendar/conduits/calendar/calendar-conduit.c
index bdf6e4b01a..fb6744e851 100644
--- a/calendar/conduits/calendar/calendar-conduit.c
+++ b/calendar/conduits/calendar/calendar-conduit.c
@@ -126,8 +126,8 @@ calconduit_load_configuration (guint32 pilot_id)
g_object_ref_sink (config);
if (!gnome_pilot_conduit_config_is_enabled (config, &c->sync_type))
c->sync_type = GnomePilotConduitSyncTypeNotSet;
- gtk_object_unref (GTK_OBJECT (config));
- gtk_object_unref (GTK_OBJECT (management));
+ g_object_unref (config);
+ g_object_unref (management);
/* Custom settings */
g_snprintf (prefix, 255, "/gnome-pilot.d/e-calendar-conduit/Pilot_%u/", pilot_id);
@@ -2109,34 +2109,34 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
g_assert (retval != NULL);
ctxt = e_calendar_context_new (pilot_id);
- gtk_object_set_data (GTK_OBJECT (retval), "calconduit_context", ctxt);
+ g_object_set_data (G_OBJECT (retval), "calconduit_context", ctxt);
/* Sync signals */
- gtk_signal_connect (retval, "pre_sync", (GtkSignalFunc) pre_sync, ctxt);
- gtk_signal_connect (retval, "post_sync", (GtkSignalFunc) post_sync, ctxt);
+ g_signal_connect (retval, "pre_sync", G_CALLBACK (pre_sync), ctxt);
+ g_signal_connect (retval, "post_sync", G_CALLBACK (post_sync), ctxt);
- gtk_signal_connect (retval, "set_pilot_id", (GtkSignalFunc) set_pilot_id, ctxt);
- gtk_signal_connect (retval, "set_status_cleared", (GtkSignalFunc) set_status_cleared, ctxt);
+ g_signal_connect (retval, "set_pilot_id", G_CALLBACK (set_pilot_id), ctxt);
+ g_signal_connect (retval, "set_status_cleared", G_CALLBACK (set_status_cleared), ctxt);
- gtk_signal_connect (retval, "for_each", (GtkSignalFunc) for_each, ctxt);
- gtk_signal_connect (retval, "for_each_modified", (GtkSignalFunc) for_each_modified, ctxt);
- gtk_signal_connect (retval, "compare", (GtkSignalFunc) compare, ctxt);
+ g_signal_connect (retval, "for_each", G_CALLBACK (for_each), ctxt);
+ g_signal_connect (retval, "for_each_modified", G_CALLBACK (for_each_modified), ctxt);
+ g_signal_connect (retval, "compare", G_CALLBACK (compare), ctxt);
- gtk_signal_connect (retval, "add_record", (GtkSignalFunc) add_record, ctxt);
- gtk_signal_connect (retval, "replace_record", (GtkSignalFunc) replace_record, ctxt);
- gtk_signal_connect (retval, "delete_record", (GtkSignalFunc) delete_record, ctxt);
- gtk_signal_connect (retval, "archive_record", (GtkSignalFunc) archive_record, ctxt);
+ g_signal_connect (retval, "add_record", G_CALLBACK (add_record), ctxt);
+ g_signal_connect (retval, "replace_record", G_CALLBACK (replace_record), ctxt);
+ g_signal_connect (retval, "delete_record", G_CALLBACK (delete_record), ctxt);
+ g_signal_connect (retval, "archive_record", G_CALLBACK (archive_record), ctxt);
- gtk_signal_connect (retval, "match", (GtkSignalFunc) match, ctxt);
- gtk_signal_connect (retval, "free_match", (GtkSignalFunc) free_match, ctxt);
+ g_signal_connect (retval, "match", G_CALLBACK (match), ctxt);
+ g_signal_connect (retval, "free_match", G_CALLBACK (free_match), ctxt);
- gtk_signal_connect (retval, "prepare", (GtkSignalFunc) prepare, ctxt);
+ g_signal_connect (retval, "prepare", G_CALLBACK (prepare), ctxt);
/* Gui Settings */
- gtk_signal_connect (retval, "create_settings_window", (GtkSignalFunc) create_settings_window, ctxt);
- gtk_signal_connect (retval, "display_settings", (GtkSignalFunc) display_settings, ctxt);
- gtk_signal_connect (retval, "save_settings", (GtkSignalFunc) save_settings, ctxt);
- gtk_signal_connect (retval, "revert_settings", (GtkSignalFunc) revert_settings, ctxt);
+ g_signal_connect (retval, "create_settings_window", G_CALLBACK (create_settings_window), ctxt);
+ g_signal_connect (retval, "display_settings", G_CALLBACK (display_settings), ctxt);
+ g_signal_connect (retval, "save_settings", G_CALLBACK (save_settings), ctxt);
+ g_signal_connect (retval, "revert_settings", G_CALLBACK (revert_settings), ctxt);
return GNOME_PILOT_CONDUIT (retval);
}
@@ -2147,7 +2147,7 @@ conduit_destroy_gpilot_conduit (GnomePilotConduit *conduit)
GtkObject *obj = GTK_OBJECT (conduit);
ECalConduitContext *ctxt;
- ctxt = gtk_object_get_data (obj, "calconduit_context");
+ ctxt = g_object_get_data (G_OBJECT (obj), "calconduit_context");
e_calendar_context_destroy (ctxt);
gtk_object_destroy (obj);
diff --git a/calendar/conduits/memo/memo-conduit.c b/calendar/conduits/memo/memo-conduit.c
index 8d4ba9d25c..33178be061 100644
--- a/calendar/conduits/memo/memo-conduit.c
+++ b/calendar/conduits/memo/memo-conduit.c
@@ -131,8 +131,8 @@ memoconduit_load_configuration (guint32 pilot_id)
g_object_ref_sink (config);
if (!gnome_pilot_conduit_config_is_enabled (config, &c->sync_type))
c->sync_type = GnomePilotConduitSyncTypeNotSet;
- gtk_object_unref (GTK_OBJECT (config));
- gtk_object_unref (GTK_OBJECT (management));
+ g_object_unref (config);
+ g_object_unref (management);
/* Custom settings */
gnome_config_push_prefix (prefix);
@@ -1393,33 +1393,33 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
g_assert (retval != NULL);
ctxt = e_memo_context_new (pilot_id);
- gtk_object_set_data (GTK_OBJECT (retval), "memoconduit_context", ctxt);
+ g_object_set_data (G_OBJECT (retval), "memoconduit_context", ctxt);
- gtk_signal_connect (retval, "pre_sync", (GtkSignalFunc) pre_sync, ctxt);
- gtk_signal_connect (retval, "post_sync", (GtkSignalFunc) post_sync, ctxt);
+ g_signal_connect (retval, "pre_sync", G_CALLBACK (pre_sync), ctxt);
+ g_signal_connect (retval, "post_sync", G_CALLBACK (post_sync), ctxt);
- gtk_signal_connect (retval, "set_pilot_id", (GtkSignalFunc) set_pilot_id, ctxt);
- gtk_signal_connect (retval, "set_status_cleared", (GtkSignalFunc) set_status_cleared, ctxt);
+ g_signal_connect (retval, "set_pilot_id", G_CALLBACK (set_pilot_id), ctxt);
+ g_signal_connect (retval, "set_status_cleared", G_CALLBACK (set_status_cleared), ctxt);
- gtk_signal_connect (retval, "for_each", (GtkSignalFunc) for_each, ctxt);
- gtk_signal_connect (retval, "for_each_modified", (GtkSignalFunc) for_each_modified, ctxt);
- gtk_signal_connect (retval, "compare", (GtkSignalFunc) compare, ctxt);
+ g_signal_connect (retval, "for_each", G_CALLBACK (for_each), ctxt);
+ g_signal_connect (retval, "for_each_modified", G_CALLBACK (for_each_modified), ctxt);
+ g_signal_connect (retval, "compare", G_CALLBACK (compare), ctxt);
- gtk_signal_connect (retval, "add_record", (GtkSignalFunc) add_record, ctxt);
- gtk_signal_connect (retval, "replace_record", (GtkSignalFunc) replace_record, ctxt);
- gtk_signal_connect (retval, "delete_record", (GtkSignalFunc) delete_record, ctxt);
- gtk_signal_connect (retval, "archive_record", (GtkSignalFunc) archive_record, ctxt);
+ g_signal_connect (retval, "add_record", G_CALLBACK (add_record), ctxt);
+ g_signal_connect (retval, "replace_record", G_CALLBACK (replace_record), ctxt);
+ g_signal_connect (retval, "delete_record", G_CALLBACK (delete_record), ctxt);
+ g_signal_connect (retval, "archive_record", G_CALLBACK (archive_record), ctxt);
- gtk_signal_connect (retval, "match", (GtkSignalFunc) match, ctxt);
- gtk_signal_connect (retval, "free_match", (GtkSignalFunc) free_match, ctxt);
+ g_signal_connect (retval, "match", G_CALLBACK (match), ctxt);
+ g_signal_connect (retval, "free_match", G_CALLBACK (free_match), ctxt);
- gtk_signal_connect (retval, "prepare", (GtkSignalFunc) prepare, ctxt);
+ g_signal_connect (retval, "prepare", G_CALLBACK (prepare), ctxt);
/* Gui Settings */
- gtk_signal_connect (retval, "create_settings_window", (GtkSignalFunc) create_settings_window, ctxt);
- gtk_signal_connect (retval, "display_settings", (GtkSignalFunc) display_settings, ctxt);
- gtk_signal_connect (retval, "save_settings", (GtkSignalFunc) save_settings, ctxt);
- gtk_signal_connect (retval, "revert_settings", (GtkSignalFunc) revert_settings, ctxt);
+ g_signal_connect (retval, "create_settings_window", G_CALLBACK (create_settings_window), ctxt);
+ g_signal_connect (retval, "display_settings", G_CALLBACK (display_settings), ctxt);
+ g_signal_connect (retval, "save_settings", G_CALLBACK (save_settings), ctxt);
+ g_signal_connect (retval, "revert_settings", G_CALLBACK (revert_settings), ctxt);
return GNOME_PILOT_CONDUIT (retval);
}
@@ -1430,7 +1430,7 @@ conduit_destroy_gpilot_conduit (GnomePilotConduit *conduit)
GtkObject *obj = GTK_OBJECT (conduit);
EMemoConduitContext *ctxt;
- ctxt = gtk_object_get_data (obj, "memoconduit_context");
+ ctxt = g_object_get_data (G_OBJECT (obj), "memoconduit_context");
e_memo_context_destroy (ctxt);
gtk_object_destroy (obj);
diff --git a/calendar/conduits/todo/todo-conduit.c b/calendar/conduits/todo/todo-conduit.c
index e8505e926d..a565bdf009 100644
--- a/calendar/conduits/todo/todo-conduit.c
+++ b/calendar/conduits/todo/todo-conduit.c
@@ -133,8 +133,8 @@ todoconduit_load_configuration (guint32 pilot_id)
g_object_ref_sink (config);
if (!gnome_pilot_conduit_config_is_enabled (config, &c->sync_type))
c->sync_type = GnomePilotConduitSyncTypeNotSet;
- gtk_object_unref (GTK_OBJECT (config));
- gtk_object_unref (GTK_OBJECT (management));
+ g_object_unref (config);
+ g_object_unref (management);
/* Custom settings */
gnome_config_push_prefix (prefix);
@@ -1582,33 +1582,33 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
g_assert (retval != NULL);
ctxt = e_todo_context_new (pilot_id);
- gtk_object_set_data (GTK_OBJECT (retval), "todoconduit_context", ctxt);
+ g_object_set_data (G_OBJECT (retval), "todoconduit_context", ctxt);
- gtk_signal_connect (retval, "pre_sync", (GtkSignalFunc) pre_sync, ctxt);
- gtk_signal_connect (retval, "post_sync", (GtkSignalFunc) post_sync, ctxt);
+ g_signal_connect (retval, "pre_sync", G_CALLBACK (pre_sync), ctxt);
+ g_signal_connect (retval, "post_sync", G_CALLBACK (post_sync), ctxt);
- gtk_signal_connect (retval, "set_pilot_id", (GtkSignalFunc) set_pilot_id, ctxt);
- gtk_signal_connect (retval, "set_status_cleared", (GtkSignalFunc) set_status_cleared, ctxt);
+ g_signal_connect (retval, "set_pilot_id", G_CALLBACK (set_pilot_id), ctxt);
+ g_signal_connect (retval, "set_status_cleared", G_CALLBACK (set_status_cleared), ctxt);
- gtk_signal_connect (retval, "for_each", (GtkSignalFunc) for_each, ctxt);
- gtk_signal_connect (retval, "for_each_modified", (GtkSignalFunc) for_each_modified, ctxt);
- gtk_signal_connect (retval, "compare", (GtkSignalFunc) compare, ctxt);
+ g_signal_connect (retval, "for_each", G_CALLBACK (for_each), ctxt);
+ g_signal_connect (retval, "for_each_modified", G_CALLBACK (for_each_modified), ctxt);
+ g_signal_connect (retval, "compare", G_CALLBACK (compare), ctxt);
- gtk_signal_connect (retval, "add_record", (GtkSignalFunc) add_record, ctxt);
- gtk_signal_connect (retval, "replace_record", (GtkSignalFunc) replace_record, ctxt);
- gtk_signal_connect (retval, "delete_record", (GtkSignalFunc) delete_record, ctxt);
- gtk_signal_connect (retval, "archive_record", (GtkSignalFunc) archive_record, ctxt);
+ g_signal_connect (retval, "add_record", G_CALLBACK (add_record), ctxt);
+ g_signal_connect (retval, "replace_record", G_CALLBACK (replace_record), ctxt);
+ g_signal_connect (retval, "delete_record", G_CALLBACK (delete_record), ctxt);
+ g_signal_connect (retval, "archive_record", G_CALLBACK (archive_record), ctxt);
- gtk_signal_connect (retval, "match", (GtkSignalFunc) match, ctxt);
- gtk_signal_connect (retval, "free_match", (GtkSignalFunc) free_match, ctxt);
+ g_signal_connect (retval, "match", G_CALLBACK (match), ctxt);
+ g_signal_connect (retval, "free_match", G_CALLBACK (free_match), ctxt);
- gtk_signal_connect (retval, "prepare", (GtkSignalFunc) prepare, ctxt);
+ g_signal_connect (retval, "prepare", G_CALLBACK (prepare), ctxt);
/* Gui Settings */
- gtk_signal_connect (retval, "create_settings_window", (GtkSignalFunc) create_settings_window, ctxt);
- gtk_signal_connect (retval, "display_settings", (GtkSignalFunc) display_settings, ctxt);
- gtk_signal_connect (retval, "save_settings", (GtkSignalFunc) save_settings, ctxt);
- gtk_signal_connect (retval, "revert_settings", (GtkSignalFunc) revert_settings, ctxt);
+ g_signal_connect (retval, "create_settings_window", G_CALLBACK (create_settings_window), ctxt);
+ g_signal_connect (retval, "display_settings", G_CALLBACK (display_settings), ctxt);
+ g_signal_connect (retval, "save_settings", G_CALLBACK (save_settings), ctxt);
+ g_signal_connect (retval, "revert_settings", G_CALLBACK (revert_settings), ctxt);
return GNOME_PILOT_CONDUIT (retval);
}
@@ -1619,7 +1619,7 @@ conduit_destroy_gpilot_conduit (GnomePilotConduit *conduit)
GtkObject *obj = GTK_OBJECT (conduit);
EToDoConduitContext *ctxt;
- ctxt = gtk_object_get_data (obj, "todoconduit_context");
+ ctxt = g_object_get_data (G_OBJECT (obj), "todoconduit_context");
e_todo_context_destroy (ctxt);
gtk_object_destroy (obj);
diff --git a/calendar/gui/cal-search-bar.c b/calendar/gui/cal-search-bar.c
index 58ba068355..6fa9aa501c 100644
--- a/calendar/gui/cal-search-bar.c
+++ b/calendar/gui/cal-search-bar.c
@@ -147,22 +147,24 @@ cal_search_bar_class_init (CalSearchBarClass *klass)
ESearchBarClass *search_bar_class = E_SEARCH_BAR_CLASS (klass);
cal_search_bar_signals[SEXP_CHANGED] =
- gtk_signal_new ("sexp_changed",
- GTK_RUN_FIRST,
- G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (CalSearchBarClass, sexp_changed),
- gtk_marshal_NONE__STRING,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_STRING);
+ g_signal_new ("sexp_changed",
+ G_TYPE_FROM_CLASS (object_class),
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (CalSearchBarClass, sexp_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__STRING,
+ G_TYPE_NONE, 1,
+ G_TYPE_STRING);
cal_search_bar_signals[CATEGORY_CHANGED] =
- gtk_signal_new ("category_changed",
- GTK_RUN_FIRST,
- G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (CalSearchBarClass, category_changed),
- gtk_marshal_NONE__STRING,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_STRING);
+ g_signal_new ("category_changed",
+ G_TYPE_FROM_CLASS (object_class),
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (CalSearchBarClass, category_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__STRING,
+ G_TYPE_NONE, 1,
+ G_TYPE_STRING);
klass->sexp_changed = NULL;
klass->category_changed = NULL;
@@ -246,8 +248,7 @@ cal_search_bar_destroy (GtkObject *object)
static void
notify_sexp_changed (CalSearchBar *cal_search, const char *sexp)
{
- gtk_signal_emit (GTK_OBJECT (cal_search), cal_search_bar_signals[SEXP_CHANGED],
- sexp);
+ g_signal_emit (GTK_OBJECT (cal_search), cal_search_bar_signals[SEXP_CHANGED], 0, sexp);
}
/* Returns the string of the currently selected category, NULL for "Unmatched" and "All
@@ -522,8 +523,7 @@ regen_view_query (CalSearchBar *cal_search)
notify_category_is (cal_search);
category = cal_search_bar_get_category (cal_search);
- gtk_signal_emit (GTK_OBJECT (cal_search), cal_search_bar_signals[CATEGORY_CHANGED],
- category);
+ g_signal_emit (GTK_OBJECT (cal_search), cal_search_bar_signals[CATEGORY_CHANGED], 0, category);
}
#endif
diff --git a/calendar/gui/cal-search-bar.h b/calendar/gui/cal-search-bar.h
index 8b31f847be..a80e5b0c44 100644
--- a/calendar/gui/cal-search-bar.h
+++ b/calendar/gui/cal-search-bar.h
@@ -29,11 +29,11 @@ G_BEGIN_DECLS
#define TYPE_CAL_SEARCH_BAR (cal_search_bar_get_type ())
-#define CAL_SEARCH_BAR(obj) (GTK_CHECK_CAST ((obj), TYPE_CAL_SEARCH_BAR, CalSearchBar))
-#define CAL_SEARCH_BAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), TYPE_CAL_SEARCH_BAR, \
+#define CAL_SEARCH_BAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CAL_SEARCH_BAR, CalSearchBar))
+#define CAL_SEARCH_BAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CAL_SEARCH_BAR, \
CalSearchBarClass))
-#define IS_CAL_SEARCH_BAR(obj) (GTK_CHECK_TYPE ((obj), TYPE_CAL_SEARCH_BAR))
-#define IS_CAL_SEARCH_BAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), TYPE_CAL_SEARCH_BAR))
+#define IS_CAL_SEARCH_BAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CAL_SEARCH_BAR))
+#define IS_CAL_SEARCH_BAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CAL_SEARCH_BAR))
typedef struct CalSearchBarPrivate CalSearchBarPrivate;
@@ -67,7 +67,7 @@ typedef struct {
void (* category_changed) (CalSearchBar *cal_search, const char *category);
} CalSearchBarClass;
-GtkType cal_search_bar_get_type (void);
+GType cal_search_bar_get_type (void);
CalSearchBar *cal_search_bar_construct (CalSearchBar *cal_search, guint32 flags);
diff --git a/calendar/gui/calendar-commands.c b/calendar/gui/calendar-commands.c
index e3fddaf99f..7f787668e7 100644
--- a/calendar/gui/calendar-commands.c
+++ b/calendar/gui/calendar-commands.c
@@ -522,9 +522,8 @@ gcal_calendar_focus_change_cb (GnomeCalendar *gcal, gboolean in, gpointer data)
calendar_control_sensitize_calendar_commands (control, gcal, TRUE);
focus->calendar_focused = TRUE;
} else if (focus->calendar_focused) {
- gtk_signal_disconnect_by_func (GTK_OBJECT (gcal),
- G_CALLBACK (gcal_calendar_selection_changed_cb),
- control);
+ g_signal_handlers_disconnect_by_func (
+ gcal, G_CALLBACK (gcal_calendar_selection_changed_cb), control);
calendar_control_sensitize_calendar_commands (control, gcal, FALSE);
focus->calendar_focused = FALSE;
}
@@ -553,9 +552,8 @@ gcal_taskpad_focus_change_cb (GnomeCalendar *gcal, gboolean in, gpointer data)
* of blindly assumming that we are getting this event because
* the taskpad was in fact focused.
*/
- gtk_signal_disconnect_by_func (GTK_OBJECT (gcal),
- G_CALLBACK (gcal_taskpad_selection_changed_cb),
- control);
+ g_signal_handlers_disconnect_by_func (
+ gcal, G_CALLBACK (gcal_taskpad_selection_changed_cb), control);
sensitize_taskpad_commands (gcal, control, FALSE);
focus->taskpad_focused = FALSE;
}
diff --git a/calendar/gui/calendar-view-factory.h b/calendar/gui/calendar-view-factory.h
index 4489277451..9185ee0ccc 100644
--- a/calendar/gui/calendar-view-factory.h
+++ b/calendar/gui/calendar-view-factory.h
@@ -29,12 +29,12 @@ G_BEGIN_DECLS
#define TYPE_CALENDAR_VIEW_FACTORY (calendar_view_factory_get_type ())
-#define CALENDAR_VIEW_FACTORY(obj) (GTK_CHECK_CAST ((obj), TYPE_CALENDAR_VIEW_FACTORY, \
+#define CALENDAR_VIEW_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CALENDAR_VIEW_FACTORY, \
CalendarViewFactory))
-#define CALENDAR_VIEW_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), \
+#define CALENDAR_VIEW_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), \
TYPE_CALENDAR_VIEW_FACTORY, CalendarViewClass))
-#define IS_CALENDAR_VIEW_FACTORY(obj) (GTK_CHECK_TYPE ((obj), TYPE_CALENDAR_VIEW_FACTORY))
-#define IS_CALENDAR_VIEW_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), \
+#define IS_CALENDAR_VIEW_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CALENDAR_VIEW_FACTORY))
+#define IS_CALENDAR_VIEW_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), \
TYPE_CALENDAR_VIEW_FACTORY))
typedef struct _CalendarViewFactoryPrivate CalendarViewFactoryPrivate;
@@ -50,7 +50,7 @@ typedef struct {
GalViewFactoryClass parent_class;
} CalendarViewFactoryClass;
-GtkType calendar_view_factory_get_type (void);
+GType calendar_view_factory_get_type (void);
CalendarViewFactory *calendar_view_factory_construct (CalendarViewFactory *cal_view_factory,
GnomeCalendarViewType view_type);
diff --git a/calendar/gui/calendar-view.h b/calendar/gui/calendar-view.h
index 48a01257f3..72e9972419 100644
--- a/calendar/gui/calendar-view.h
+++ b/calendar/gui/calendar-view.h
@@ -29,11 +29,11 @@ G_BEGIN_DECLS
#define TYPE_CALENDAR_VIEW (calendar_view_get_type ())
-#define CALENDAR_VIEW(obj) (GTK_CHECK_CAST ((obj), TYPE_CALENDAR_VIEW, CalendarView))
-#define CALENDAR_VIEW_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), TYPE_CALENDAR_VIEW, \
+#define CALENDAR_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CALENDAR_VIEW, CalendarView))
+#define CALENDAR_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CALENDAR_VIEW, \
CalendarViewClass))
-#define IS_CALENDAR_VIEW(obj) (GTK_CHECK_TYPE ((obj), TYPE_CALENDAR_VIEW))
-#define IS_CALENDAR_VIEW_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), TYPE_CALENDAR_VIEW))
+#define IS_CALENDAR_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CALENDAR_VIEW))
+#define IS_CALENDAR_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CALENDAR_VIEW))
typedef struct _CalendarViewPrivate CalendarViewPrivate;
@@ -48,7 +48,7 @@ typedef struct {
GalViewClass parent_class;
} CalendarViewClass;
-GtkType calendar_view_get_type (void);
+GType calendar_view_get_type (void);
CalendarView *calendar_view_construct (CalendarView *cal_view,
GnomeCalendarViewType view_type,
diff --git a/calendar/gui/comp-editor-factory.h b/calendar/gui/comp-editor-factory.h
index d9ca0ab824..ecc262cf26 100644
--- a/calendar/gui/comp-editor-factory.h
+++ b/calendar/gui/comp-editor-factory.h
@@ -27,12 +27,12 @@
#define TYPE_COMP_EDITOR_FACTORY (comp_editor_factory_get_type ())
-#define COMP_EDITOR_FACTORY(obj) (GTK_CHECK_CAST ((obj), TYPE_COMP_EDITOR_FACTORY, \
+#define COMP_EDITOR_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_COMP_EDITOR_FACTORY, \
CompEditorFactory))
-#define COMP_EDITOR_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), \
+#define COMP_EDITOR_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), \
TYPE_COMP_EDITOR_FACTORY, CompEditorFactoryClass))
-#define IS_COMP_EDITOR_FACTORY(obj) (GTK_CHECK_TYPE ((obj), TYPE_COMP_EDITOR_FACTORY))
-#define IS_COMP_EDITOR_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), TYPE_COMP_EDITOR_FACTORY))
+#define IS_COMP_EDITOR_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_COMP_EDITOR_FACTORY))
+#define IS_COMP_EDITOR_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_COMP_EDITOR_FACTORY))
typedef struct CompEditorFactoryPrivate CompEditorFactoryPrivate;
@@ -49,7 +49,7 @@ typedef struct {
POA_GNOME_Evolution_Calendar_CompEditorFactory__epv epv;
} CompEditorFactoryClass;
-GtkType comp_editor_factory_get_type (void);
+GType comp_editor_factory_get_type (void);
CompEditorFactory *comp_editor_factory_new (void);
diff --git a/calendar/gui/dialogs/comp-editor-page.c b/calendar/gui/dialogs/comp-editor-page.c
index 174f7eb50d..609c872db7 100644
--- a/calendar/gui/dialogs/comp-editor-page.c
+++ b/calendar/gui/dialogs/comp-editor-page.c
@@ -33,9 +33,9 @@
static void comp_editor_page_class_init (CompEditorPageClass *class);
static void comp_editor_page_init (CompEditorPage *page);
-static void comp_editor_page_destroy (GtkObject *object);
+static void comp_editor_page_dispose (GObject *object);
-static GtkObjectClass *parent_class = NULL;
+static gpointer parent_class;
/* Signal IDs */
@@ -64,40 +64,54 @@ static guint comp_editor_page_signals[LAST_SIGNAL];
*
* Return value: The type ID of the #CompEditorPage class.
**/
-GtkType
+GType
comp_editor_page_get_type (void)
{
- static GtkType comp_editor_page_type = 0;
+ static GType type = 0;
- if (!comp_editor_page_type) {
- static const GtkTypeInfo comp_editor_page_info = {
- "CompEditorPage",
- sizeof (CompEditorPage),
+ if (G_UNLIKELY (type == 0)) {
+ static const GTypeInfo type_info = {
sizeof (CompEditorPageClass),
- (GtkClassInitFunc) comp_editor_page_class_init,
- (GtkObjectInitFunc) comp_editor_page_init,
- NULL, /* reserved_1 */
- NULL, /* reserved_2 */
- (GtkClassInitFunc) NULL
+ (GBaseInitFunc) NULL,
+ (GBaseFinalizeFunc) NULL,
+ (GClassInitFunc) comp_editor_page_class_init,
+ (GClassFinalizeFunc) NULL,
+ NULL, /* class_data */
+ sizeof (CompEditorPage),
+ 0, /* n_preallocs */
+ (GInstanceInitFunc) comp_editor_page_init,
+ NULL /* value_table */
};
- comp_editor_page_type =
- gtk_type_unique (GTK_TYPE_OBJECT,
- &comp_editor_page_info);
+ type = g_type_register_static (
+ G_TYPE_OBJECT, "CompEditorPage", &type_info, 0);
}
- return comp_editor_page_type;
+ return type;
}
/* Class initialization function for the abstract editor page */
static void
comp_editor_page_class_init (CompEditorPageClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
+
+ parent_class = g_type_class_peek_parent (class);
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->dispose = comp_editor_page_dispose;
- object_class = (GtkObjectClass *) class;
+ class->changed = NULL;
+ class->summary_changed = NULL;
+ class->dates_changed = NULL;
- parent_class = g_type_class_ref(GTK_TYPE_OBJECT);
+ class->get_widget = NULL;
+ class->focus_main_widget = NULL;
+ class->fill_widgets = NULL;
+ class->fill_component = NULL;
+ class->fill_timezones = NULL;
+ class->set_summary = NULL;
+ class->set_dates = NULL;
comp_editor_page_signals[CHANGED] =
g_signal_new ("changed",
@@ -159,20 +173,6 @@ comp_editor_page_class_init (CompEditorPageClass *class)
NULL, NULL,
g_cclosure_marshal_VOID__POINTER,
G_TYPE_NONE, 1, G_TYPE_POINTER);
-
- class->changed = NULL;
- class->summary_changed = NULL;
- class->dates_changed = NULL;
-
- class->get_widget = NULL;
- class->focus_main_widget = NULL;
- class->fill_widgets = NULL;
- class->fill_component = NULL;
- class->fill_timezones = NULL;
- class->set_summary = NULL;
- class->set_dates = NULL;
-
- object_class->destroy = comp_editor_page_destroy;
}
@@ -186,7 +186,7 @@ comp_editor_page_init (CompEditorPage *page)
static void
-comp_editor_page_destroy (GtkObject *object)
+comp_editor_page_dispose (GObject *object)
{
CompEditorPage *page;
@@ -205,8 +205,7 @@ comp_editor_page_destroy (GtkObject *object)
page->accel_group = NULL;
}
- if (GTK_OBJECT_CLASS (parent_class)->destroy)
- (* GTK_OBJECT_CLASS (parent_class)->destroy) (object);
+ G_OBJECT_CLASS (parent_class)->dispose (object);
}
@@ -362,9 +361,9 @@ comp_editor_page_unset_focused_widget (CompEditorPage *page, GtkWidget *widget)
g_return_if_fail (page!= NULL);
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
- gtk_signal_emit (GTK_OBJECT (page),
- comp_editor_page_signals[FOCUS_OUT],
- widget);
+ g_signal_emit (page,
+ comp_editor_page_signals[FOCUS_OUT], 0,
+ widget);
}
@@ -379,9 +378,9 @@ comp_editor_page_set_focused_widget (CompEditorPage *page, GtkWidget *widget)
g_return_if_fail (page!= NULL);
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
- gtk_signal_emit (GTK_OBJECT (page),
- comp_editor_page_signals[FOCUS_IN],
- widget);
+ g_signal_emit (page,
+ comp_editor_page_signals[FOCUS_IN], 0,
+ widget);
}
/**
@@ -414,7 +413,7 @@ comp_editor_page_notify_changed (CompEditorPage *page)
g_return_if_fail (page != NULL);
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
- gtk_signal_emit (GTK_OBJECT (page), comp_editor_page_signals[CHANGED]);
+ g_signal_emit (page, comp_editor_page_signals[CHANGED], 0);
}
/**
@@ -429,7 +428,7 @@ comp_editor_page_notify_needs_send (CompEditorPage *page)
g_return_if_fail (page != NULL);
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
- gtk_signal_emit (GTK_OBJECT (page), comp_editor_page_signals[NEEDS_SEND]);
+ g_signal_emit (page, comp_editor_page_signals[NEEDS_SEND], 0);
}
/**
@@ -447,9 +446,9 @@ comp_editor_page_notify_summary_changed (CompEditorPage *page,
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
- gtk_signal_emit (GTK_OBJECT (page),
- comp_editor_page_signals[SUMMARY_CHANGED],
- summary);
+ g_signal_emit (page,
+ comp_editor_page_signals[SUMMARY_CHANGED], 0,
+ summary);
}
/**
@@ -466,9 +465,9 @@ comp_editor_page_notify_dates_changed (CompEditorPage *page,
g_return_if_fail (page != NULL);
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
- gtk_signal_emit (GTK_OBJECT (page),
- comp_editor_page_signals[DATES_CHANGED],
- dates);
+ g_signal_emit (page,
+ comp_editor_page_signals[DATES_CHANGED], 0,
+ dates);
}
/**
@@ -486,9 +485,9 @@ comp_editor_page_notify_client_changed (CompEditorPage *page,
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
comp_editor_page_set_e_cal (page, client);
- gtk_signal_emit (GTK_OBJECT (page),
- comp_editor_page_signals[CLIENT_CHANGED],
- client);
+ g_signal_emit (page,
+ comp_editor_page_signals[CLIENT_CHANGED], 0,
+ client);
}
/**
diff --git a/calendar/gui/dialogs/comp-editor-page.h b/calendar/gui/dialogs/comp-editor-page.h
index 19d8ede6f6..5a121ab92b 100644
--- a/calendar/gui/dialogs/comp-editor-page.h
+++ b/calendar/gui/dialogs/comp-editor-page.h
@@ -53,7 +53,7 @@ typedef enum {
} CompEditorPageFlags;
typedef struct {
- GtkObject object;
+ GObject object;
/* Some of the pages need the ECal to access timezone data. Also,
* the event page needs to know it to fill the source option menu. */
@@ -70,7 +70,7 @@ typedef struct {
} CompEditorPage;
typedef struct {
- GtkObjectClass parent_class;
+ GObjectClass parent_class;
/* Notification signals */
@@ -95,7 +95,7 @@ typedef struct {
void (* set_dates) (CompEditorPage *page, CompEditorPageDates *dates);
} CompEditorPageClass;
-GtkType comp_editor_page_get_type (void);
+GType comp_editor_page_get_type (void);
GtkWidget *comp_editor_page_get_widget (CompEditorPage *page);
void comp_editor_page_focus_main_widget (CompEditorPage *page);
void comp_editor_page_unset_focused_widget (CompEditorPage *page, GtkWidget *widget);
diff --git a/calendar/gui/dialogs/comp-editor.h b/calendar/gui/dialogs/comp-editor.h
index 7243808386..fa1c9eccb0 100644
--- a/calendar/gui/dialogs/comp-editor.h
+++ b/calendar/gui/dialogs/comp-editor.h
@@ -68,7 +68,7 @@ typedef enum {
COMP_EDITOR_IS_SHARED = 1 << 5
} CompEditorFlags;
-GtkType comp_editor_get_type (void);
+GType comp_editor_get_type (void);
void comp_editor_set_changed (CompEditor *editor,
gboolean changed);
gboolean comp_editor_get_changed (CompEditor *editor);
diff --git a/calendar/gui/dialogs/e-delegate-dialog.h b/calendar/gui/dialogs/e-delegate-dialog.h
index c58e668846..67787190af 100644
--- a/calendar/gui/dialogs/e-delegate-dialog.h
+++ b/calendar/gui/dialogs/e-delegate-dialog.h
@@ -48,7 +48,7 @@ struct _EDelegateDialogClass {
GtkObjectClass parent_class;
};
-GtkType e_delegate_dialog_get_type (void);
+GType e_delegate_dialog_get_type (void);
EDelegateDialog* e_delegate_dialog_construct (EDelegateDialog *etd,
const char *name,
diff --git a/calendar/gui/dialogs/event-editor.h b/calendar/gui/dialogs/event-editor.h
index 26c6d22a71..eacb87d780 100644
--- a/calendar/gui/dialogs/event-editor.h
+++ b/calendar/gui/dialogs/event-editor.h
@@ -50,7 +50,7 @@ struct _EventEditorClass {
CompEditorClass parent_class;
};
-GtkType event_editor_get_type (void);
+GType event_editor_get_type (void);
EventEditor *event_editor_construct (EventEditor *ee,
ECal *client);
EventEditor *event_editor_new (ECal *client, CompEditorFlags flags);
diff --git a/calendar/gui/dialogs/event-page.h b/calendar/gui/dialogs/event-page.h
index 0d711379c6..1620c11050 100644
--- a/calendar/gui/dialogs/event-page.h
+++ b/calendar/gui/dialogs/event-page.h
@@ -56,7 +56,7 @@ typedef struct {
} EventPageClass;
-GtkType event_page_get_type (void);
+GType event_page_get_type (void);
EventPage *event_page_construct (EventPage *epage, EMeetingStore *model, ECal *client);
EventPage *event_page_new (EMeetingStore *model, ECal *client, BonoboUIComponent *uic);
ECalComponent *event_page_get_cancel_comp (EventPage *page);
diff --git a/calendar/gui/dialogs/memo-editor.h b/calendar/gui/dialogs/memo-editor.h
index ca6b4863d6..d913628158 100644
--- a/calendar/gui/dialogs/memo-editor.h
+++ b/calendar/gui/dialogs/memo-editor.h
@@ -50,7 +50,7 @@ struct _MemoEditorClass {
CompEditorClass parent_class;
};
-GtkType memo_editor_get_type (void);
+GType memo_editor_get_type (void);
MemoEditor *memo_editor_construct (MemoEditor *te,
ECal *client);
MemoEditor *memo_editor_new (ECal *client, CompEditorFlags flags);
diff --git a/calendar/gui/dialogs/memo-page.h b/calendar/gui/dialogs/memo-page.h
index 52b419f078..964f4fba00 100644
--- a/calendar/gui/dialogs/memo-page.h
+++ b/calendar/gui/dialogs/memo-page.h
@@ -50,7 +50,7 @@ typedef struct {
CompEditorPageClass parent_class;
} MemoPageClass;
-GtkType memo_page_get_type (void);
+GType memo_page_get_type (void);
MemoPage *memo_page_construct (MemoPage *epage);
MemoPage *memo_page_new (BonoboUIComponent *uic, CompEditorPageFlags flags);
void memo_page_set_classification (MemoPage *page, ECalComponentClassification class);
diff --git a/calendar/gui/dialogs/recurrence-page.c b/calendar/gui/dialogs/recurrence-page.c
index c95eb34937..cfa6b2b49d 100644
--- a/calendar/gui/dialogs/recurrence-page.c
+++ b/calendar/gui/dialogs/recurrence-page.c
@@ -966,8 +966,8 @@ month_num_submenu_selection_done_cb (GtkMenuShell *menu_shell, gpointer data)
item = gtk_menu_get_active (GTK_MENU (menu_shell));
item = gtk_menu_get_active (GTK_MENU (gtk_menu_item_get_submenu (GTK_MENU_ITEM (item))));
- month_index = GPOINTER_TO_INT (gtk_object_get_user_data (GTK_OBJECT (item)));
- gtk_object_set_user_data (GTK_OBJECT (data), GINT_TO_POINTER (month_index));
+ month_index = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (item), "data"));
+ g_object_set_data (G_OBJECT (data), "data", GINT_TO_POINTER (month_index));
}
/* Creates the option menu for the monthly recurrence number */
@@ -981,7 +981,7 @@ make_recur_month_num_submenu (const char *title, int start, int end)
for (i = start; i < end; i++) {
item = gtk_menu_item_new_with_label (_(e_cal_recur_nth[i]));
gtk_menu_shell_append(GTK_MENU_SHELL(submenu), item);
- gtk_object_set_user_data (GTK_OBJECT (item), GINT_TO_POINTER (i + 1));
+ g_object_set_data (G_OBJECT (item), "data", GINT_TO_POINTER (i + 1));
gtk_widget_show (item);
}
@@ -1071,7 +1071,7 @@ make_recur_month_num_menu (int month_index)
gtk_menu_shell_append(GTK_MENU_SHELL(submenu), item);
gtk_menu_item_set_submenu (GTK_MENU_ITEM (submenu_item), submenu);
- gtk_object_set_user_data (GTK_OBJECT (submenu_item), GINT_TO_POINTER (month_index));
+ g_object_set_data (G_OBJECT (submenu_item), "data", GINT_TO_POINTER (month_index));
g_signal_connect((submenu), "selection_done",
G_CALLBACK (month_num_submenu_selection_done_cb),
submenu_item);
@@ -1140,7 +1140,7 @@ month_num_menu_selection_done_cb (GtkMenuShell *menu_shell, gpointer data)
GtkWidget *label, *item;
item = gtk_menu_get_active (GTK_MENU (menu_shell));
- priv->month_index = GPOINTER_TO_INT (gtk_object_get_user_data (GTK_OBJECT (item)));
+ priv->month_index = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (item), "data"));
month_num = MONTH_NUM_DAY;
e_dialog_option_menu_set (priv->month_num_menu, month_num, month_num_options_map);
diff --git a/calendar/gui/dialogs/recurrence-page.h b/calendar/gui/dialogs/recurrence-page.h
index b21a9994c1..2f4e94d5ec 100644
--- a/calendar/gui/dialogs/recurrence-page.h
+++ b/calendar/gui/dialogs/recurrence-page.h
@@ -51,7 +51,7 @@ typedef struct {
} RecurrencePageClass;
-GtkType recurrence_page_get_type (void);
+GType recurrence_page_get_type (void);
RecurrencePage *recurrence_page_construct (RecurrencePage *rpage);
RecurrencePage *recurrence_page_new (void);
diff --git a/calendar/gui/dialogs/schedule-page.h b/calendar/gui/dialogs/schedule-page.h
index 39fdacb5e5..cc09918ed2 100644
--- a/calendar/gui/dialogs/schedule-page.h
+++ b/calendar/gui/dialogs/schedule-page.h
@@ -49,7 +49,7 @@ typedef struct {
} SchedulePageClass;
-GtkType schedule_page_get_type (void);
+GType schedule_page_get_type (void);
SchedulePage *schedule_page_construct (SchedulePage *mpage, EMeetingStore *ems);
SchedulePage *schedule_page_new (EMeetingStore *ems);
void schedule_page_set_name_selector (SchedulePage *spage, ENameSelector *name_selector);
diff --git a/calendar/gui/dialogs/task-details-page.h b/calendar/gui/dialogs/task-details-page.h
index a7d06e49a6..a47cafa9ed 100644
--- a/calendar/gui/dialogs/task-details-page.h
+++ b/calendar/gui/dialogs/task-details-page.h
@@ -50,7 +50,7 @@ typedef struct {
} TaskDetailsPageClass;
-GtkType task_details_page_get_type (void);
+GType task_details_page_get_type (void);
TaskDetailsPage *task_details_page_construct (TaskDetailsPage *tdpage);
TaskDetailsPage *task_details_page_new (void);
diff --git a/calendar/gui/dialogs/task-editor.h b/calendar/gui/dialogs/task-editor.h
index 9d823f7ba3..2980c7c2ae 100644
--- a/calendar/gui/dialogs/task-editor.h
+++ b/calendar/gui/dialogs/task-editor.h
@@ -51,7 +51,7 @@ struct _TaskEditorClass {
CompEditorClass parent_class;
};
-GtkType task_editor_get_type (void);
+GType task_editor_get_type (void);
TaskEditor *task_editor_construct (TaskEditor *te,
ECal *client);
TaskEditor *task_editor_new (ECal *client, CompEditorFlags flags);
diff --git a/calendar/gui/dialogs/task-page.h b/calendar/gui/dialogs/task-page.h
index 37041a033e..f97ad923ea 100644
--- a/calendar/gui/dialogs/task-page.h
+++ b/calendar/gui/dialogs/task-page.h
@@ -55,7 +55,7 @@ typedef struct {
CompEditorPageClass parent_class;
} TaskPageClass;
-GtkType task_page_get_type (void);
+GType task_page_get_type (void);
TaskPage *task_page_construct (TaskPage *epage, EMeetingStore *model, ECal *client);
TaskPage *task_page_new (EMeetingStore *model, ECal *client, BonoboUIComponent *uic);
ECalComponent * task_page_get_cancel_comp (TaskPage *page);
diff --git a/calendar/gui/e-alarm-list.c b/calendar/gui/e-alarm-list.c
index 1a3dd3dc08..05d532346d 100644
--- a/calendar/gui/e-alarm-list.c
+++ b/calendar/gui/e-alarm-list.c
@@ -75,7 +75,7 @@ static gboolean e_alarm_list_iter_parent (GtkTreeModel *tree_model
static GObjectClass *parent_class = NULL;
-GtkType
+GType
e_alarm_list_get_type (void)
{
static GType alarm_list_type = 0;
diff --git a/calendar/gui/e-alarm-list.h b/calendar/gui/e-alarm-list.h
index 81b044f909..3f618f51c9 100644
--- a/calendar/gui/e-alarm-list.h
+++ b/calendar/gui/e-alarm-list.h
@@ -29,11 +29,11 @@
G_BEGIN_DECLS
#define E_TYPE_ALARM_LIST (e_alarm_list_get_type ())
-#define E_ALARM_LIST(obj) (GTK_CHECK_CAST ((obj), E_TYPE_ALARM_LIST, EAlarmList))
-#define E_ALARM_LIST_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), E_TYPE_ALARM_LIST, EAlarmListClass))
-#define E_IS_ALARM_LIST(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_ALARM_LIST))
-#define E_IS_ALARM_LIST_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), E_TYPE_ALARM_LIST))
-#define E_ALARM_LIST_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), E_TYPE_ALARM_LIST, EAlarmListClass))
+#define E_ALARM_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_ALARM_LIST, EAlarmList))
+#define E_ALARM_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), E_TYPE_ALARM_LIST, EAlarmListClass))
+#define E_IS_ALARM_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_ALARM_LIST))
+#define E_IS_ALARM_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_ALARM_LIST))
+#define E_ALARM_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), E_TYPE_ALARM_LIST, EAlarmListClass))
typedef struct _EAlarmList EAlarmList;
typedef struct _EAlarmListClass EAlarmListClass;
@@ -63,7 +63,7 @@ struct _EAlarmListClass
GObjectClass parent_class;
};
-GtkType e_alarm_list_get_type (void);
+GType e_alarm_list_get_type (void);
EAlarmList *e_alarm_list_new (void);
const ECalComponentAlarm *e_alarm_list_get_alarm (EAlarmList *alarm_list, GtkTreeIter *iter);
diff --git a/calendar/gui/e-cal-component-memo-preview.h b/calendar/gui/e-cal-component-memo-preview.h
index d32ef5eb63..1d22eb640d 100644
--- a/calendar/gui/e-cal-component-memo-preview.h
+++ b/calendar/gui/e-cal-component-memo-preview.h
@@ -29,11 +29,11 @@
#include <libecal/e-cal.h>
#define E_TYPE_CAL_COMPONENT_MEMO_PREVIEW (e_cal_component_memo_preview_get_type ())
-#define E_CAL_COMPONENT_MEMO_PREVIEW(obj) (GTK_CHECK_CAST ((obj), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW, ECalComponentMemoPreview))
-#define E_CAL_COMPONENT_MEMO_PREVIEW_CLASS(klass) (GTK_CHECK_CAST_CLASS ((klass), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW, \
+#define E_CAL_COMPONENT_MEMO_PREVIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW, ECalComponentMemoPreview))
+#define E_CAL_COMPONENT_MEMO_PREVIEW_CLASS(klass) (G_TYPE_CHECK_INSTANCE_CAST_CLASS ((klass), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW, \
ECalComponentMemoPreviewClass))
-#define E_IS_CAL_COMPONENT_MEMO_PREVIEW(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW))
-#define E_IS_CAL_COMPONENT_MEMO_PREVIEW_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW))
+#define E_IS_CAL_COMPONENT_MEMO_PREVIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW))
+#define E_IS_CAL_COMPONENT_MEMO_PREVIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_CAL_COMPONENT_MEMO_PREVIEW))
typedef struct _ECalComponentMemoPreview ECalComponentMemoPreview;
typedef struct _ECalComponentMemoPreviewClass ECalComponentMemoPreviewClass;
@@ -54,7 +54,7 @@ struct _ECalComponentMemoPreviewClass {
};
-GtkType e_cal_component_memo_preview_get_type (void);
+GType e_cal_component_memo_preview_get_type (void);
GtkWidget *e_cal_component_memo_preview_new (void);
icaltimezone *e_cal_component_memo_preview_get_default_timezone (ECalComponentMemoPreview *preview);
diff --git a/calendar/gui/e-cal-component-preview.h b/calendar/gui/e-cal-component-preview.h
index 1bfb0c2f2e..a7593ac75f 100644
--- a/calendar/gui/e-cal-component-preview.h
+++ b/calendar/gui/e-cal-component-preview.h
@@ -30,11 +30,11 @@
#include <gtkhtml/gtkhtml-stream.h>
#define E_TYPE_CAL_COMPONENT_PREVIEW (e_cal_component_preview_get_type ())
-#define E_CAL_COMPONENT_PREVIEW(obj) (GTK_CHECK_CAST ((obj), E_TYPE_CAL_COMPONENT_PREVIEW, ECalComponentPreview))
-#define E_CAL_COMPONENT_PREVIEW_CLASS(klass) (GTK_CHECK_CAST_CLASS ((klass), E_TYPE_CAL_COMPONENT_PREVIEW, \
+#define E_CAL_COMPONENT_PREVIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_CAL_COMPONENT_PREVIEW, ECalComponentPreview))
+#define E_CAL_COMPONENT_PREVIEW_CLASS(klass) (G_TYPE_CHECK_INSTANCE_CAST_CLASS ((klass), E_TYPE_CAL_COMPONENT_PREVIEW, \
ECalComponentPreviewClass))
-#define E_IS_CAL_COMPONENT_PREVIEW(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_CAL_COMPONENT_PREVIEW))
-#define E_IS_CAL_COMPONENT_PREVIEW_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), E_TYPE_CAL_COMPONENT_PREVIEW))
+#define E_IS_CAL_COMPONENT_PREVIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_CAL_COMPONENT_PREVIEW))
+#define E_IS_CAL_COMPONENT_PREVIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_CAL_COMPONENT_PREVIEW))
typedef struct _ECalComponentPreview ECalComponentPreview;
typedef struct _ECalComponentPreviewClass ECalComponentPreviewClass;
@@ -55,7 +55,7 @@ struct _ECalComponentPreviewClass {
};
-GtkType e_cal_component_preview_get_type (void);
+GType e_cal_component_preview_get_type (void);
GtkWidget *e_cal_component_preview_new (void);
icaltimezone *e_cal_component_preview_get_default_timezone (ECalComponentPreview *preview);
diff --git a/calendar/gui/e-cal-list-view-config.h b/calendar/gui/e-cal-list-view-config.h
index e3c7f54a2c..6245ba9ff7 100644
--- a/calendar/gui/e-cal-list-view-config.h
+++ b/calendar/gui/e-cal-list-view-config.h
@@ -27,9 +27,9 @@
G_BEGIN_DECLS
-#define E_CAL_LIST_VIEW_CONFIG(obj) GTK_CHECK_CAST (obj, e_cal_list_view_config_get_type (), ECalListViewConfig)
-#define E_CAL_LIST_VIEW_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_cal_list_view_config_get_type (), ECalListViewConfigClass)
-#define E_IS_CAL_LIST_VIEW_CONFIG(obj) GTK_CHECK_TYPE (obj, e_cal_list_view_config_get_type ())
+#define E_CAL_LIST_VIEW_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_cal_list_view_config_get_type (), ECalListViewConfig)
+#define E_CAL_LIST_VIEW_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_cal_list_view_config_get_type (), ECalListViewConfigClass)
+#define E_IS_CAL_LIST_VIEW_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_cal_list_view_config_get_type ())
typedef struct _ECalListViewConfig ECalListViewConfig;
typedef struct _ECalListViewConfigClass ECalListViewConfigClass;
diff --git a/calendar/gui/e-cal-list-view.h b/calendar/gui/e-cal-list-view.h
index 82af6480e9..0bb90b74f8 100644
--- a/calendar/gui/e-cal-list-view.h
+++ b/calendar/gui/e-cal-list-view.h
@@ -36,9 +36,9 @@ G_BEGIN_DECLS
* ECalListView - displays calendar events in an ETable.
*/
-#define E_CAL_LIST_VIEW(obj) GTK_CHECK_CAST (obj, e_cal_list_view_get_type (), ECalListView)
-#define E_CAL_LIST_VIEW_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_cal_list_view_get_type (), ECalListViewClass)
-#define E_IS_CAL_LIST_VIEW(obj) GTK_CHECK_TYPE (obj, e_cal_list_view_get_type ())
+#define E_CAL_LIST_VIEW(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_cal_list_view_get_type (), ECalListView)
+#define E_CAL_LIST_VIEW_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_cal_list_view_get_type (), ECalListViewClass)
+#define E_IS_CAL_LIST_VIEW(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_cal_list_view_get_type ())
typedef struct _ECalListView ECalListView;
@@ -73,7 +73,7 @@ struct _ECalListViewClass
};
-GtkType e_cal_list_view_get_type (void);
+GType e_cal_list_view_get_type (void);
GtkWidget *e_cal_list_view_construct (ECalListView *cal_list_view);
GtkWidget *e_cal_list_view_new (void);
diff --git a/calendar/gui/e-calendar-table-config.h b/calendar/gui/e-calendar-table-config.h
index 93b1dadf9b..f32d6d0e81 100644
--- a/calendar/gui/e-calendar-table-config.h
+++ b/calendar/gui/e-calendar-table-config.h
@@ -27,9 +27,9 @@
G_BEGIN_DECLS
-#define E_CALENDAR_TABLE_CONFIG(obj) GTK_CHECK_CAST (obj, e_calendar_table_config_get_type (), ECalendarTableConfig)
-#define E_CALENDAR_TABLE_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_calendar_table_config_get_type (), ECalendarTableConfigClass)
-#define E_IS_CALENDAR_TABLE_CONFIG(obj) GTK_CHECK_TYPE (obj, e_calendar_table_config_get_type ())
+#define E_CALENDAR_TABLE_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_calendar_table_config_get_type (), ECalendarTableConfig)
+#define E_CALENDAR_TABLE_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_calendar_table_config_get_type (), ECalendarTableConfigClass)
+#define E_IS_CALENDAR_TABLE_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_calendar_table_config_get_type ())
typedef struct _ECalendarTableConfig ECalendarTableConfig;
typedef struct _ECalendarTableConfigClass ECalendarTableConfigClass;
diff --git a/calendar/gui/e-calendar-table.h b/calendar/gui/e-calendar-table.h
index b9ebf872a2..44be681c25 100644
--- a/calendar/gui/e-calendar-table.h
+++ b/calendar/gui/e-calendar-table.h
@@ -38,9 +38,9 @@ G_BEGIN_DECLS
*/
-#define E_CALENDAR_TABLE(obj) GTK_CHECK_CAST (obj, e_calendar_table_get_type (), ECalendarTable)
-#define E_CALENDAR_TABLE_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_calendar_table_get_type (), ECalendarTableClass)
-#define E_IS_CALENDAR_TABLE(obj) GTK_CHECK_TYPE (obj, e_calendar_table_get_type ())
+#define E_CALENDAR_TABLE(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_calendar_table_get_type (), ECalendarTable)
+#define E_CALENDAR_TABLE_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_calendar_table_get_type (), ECalendarTableClass)
+#define E_IS_CALENDAR_TABLE(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_calendar_table_get_type ())
typedef struct _ECalendarTable ECalendarTable;
@@ -78,7 +78,7 @@ struct _ECalendarTableClass {
};
-GtkType e_calendar_table_get_type (void);
+GType e_calendar_table_get_type (void);
GtkWidget* e_calendar_table_new (void);
ECalModel *e_calendar_table_get_model (ECalendarTable *cal_table);
diff --git a/calendar/gui/e-calendar-view.h b/calendar/gui/e-calendar-view.h
index 5c4be44d2b..4aaeebac2a 100644
--- a/calendar/gui/e-calendar-view.h
+++ b/calendar/gui/e-calendar-view.h
@@ -36,9 +36,9 @@ G_BEGIN_DECLS
*/
#define E_TYPE_CALENDAR_VIEW (e_calendar_view_get_type ())
-#define E_CALENDAR_VIEW(obj) GTK_CHECK_CAST (obj, e_calendar_view_get_type (), ECalendarView)
-#define E_CALENDAR_VIEW_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_calendar_view_get_type (), ECalendarViewClass)
-#define E_IS_CALENDAR_VIEW(obj) GTK_CHECK_TYPE (obj, e_calendar_view_get_type ())
+#define E_CALENDAR_VIEW(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_calendar_view_get_type (), ECalendarView)
+#define E_CALENDAR_VIEW_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_calendar_view_get_type (), ECalendarViewClass)
+#define E_IS_CALENDAR_VIEW(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_calendar_view_get_type ())
typedef enum {
E_CALENDAR_VIEW_POS_OUTSIDE,
diff --git a/calendar/gui/e-cell-date-edit-config.h b/calendar/gui/e-cell-date-edit-config.h
index c42260b956..e095f121dd 100644
--- a/calendar/gui/e-cell-date-edit-config.h
+++ b/calendar/gui/e-cell-date-edit-config.h
@@ -28,9 +28,9 @@
G_BEGIN_DECLS
-#define E_CELL_DATE_EDIT_CONFIG(obj) GTK_CHECK_CAST (obj, e_cell_date_edit_config_get_type (), ECellDateEditConfig)
-#define E_CELL_DATE_EDIT_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_cell_date_edit_config_get_type (), ECellDateEditConfigClass)
-#define E_IS_CELL_DATE_EDIT_CONFIG(obj) GTK_CHECK_TYPE (obj, e_cell_date_edit_config_get_type ())
+#define E_CELL_DATE_EDIT_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_cell_date_edit_config_get_type (), ECellDateEditConfig)
+#define E_CELL_DATE_EDIT_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_cell_date_edit_config_get_type (), ECellDateEditConfigClass)
+#define E_IS_CELL_DATE_EDIT_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_cell_date_edit_config_get_type ())
typedef struct _ECellDateEditConfig ECellDateEditConfig;
typedef struct _ECellDateEditConfigClass ECellDateEditConfigClass;
diff --git a/calendar/gui/e-cell-date-edit-text.h b/calendar/gui/e-cell-date-edit-text.h
index b0cdfd0bc9..7dca1982f9 100644
--- a/calendar/gui/e-cell-date-edit-text.h
+++ b/calendar/gui/e-cell-date-edit-text.h
@@ -35,10 +35,10 @@
G_BEGIN_DECLS
#define E_CELL_DATE_EDIT_TEXT_TYPE (e_cell_date_edit_text_get_type ())
-#define E_CELL_DATE_EDIT_TEXT(o) (GTK_CHECK_CAST ((o), E_CELL_DATE_EDIT_TEXT_TYPE, ECellDateEditText))
-#define E_CELL_DATE_EDIT_TEXT_CLASS(k) (GTK_CHECK_CLASS_CAST((k), E_CELL_DATE_EDIT_TEXT_TYPE, ECellDateEditTextClass))
-#define E_IS_CELL_DATE_EDIT_TEXT(o) (GTK_CHECK_TYPE ((o), E_CELL_DATE_EDIT_TEXT_TYPE))
-#define E_IS_CELL_DATE_EDIT_TEXT_CLASS(k) (GTK_CHECK_CLASS_TYPE ((k), E_CELL_DATE_EDIT_TEXT_TYPE))
+#define E_CELL_DATE_EDIT_TEXT(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), E_CELL_DATE_EDIT_TEXT_TYPE, ECellDateEditText))
+#define E_CELL_DATE_EDIT_TEXT_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), E_CELL_DATE_EDIT_TEXT_TYPE, ECellDateEditTextClass))
+#define E_IS_CELL_DATE_EDIT_TEXT(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), E_CELL_DATE_EDIT_TEXT_TYPE))
+#define E_IS_CELL_DATE_EDIT_TEXT_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), E_CELL_DATE_EDIT_TEXT_TYPE))
typedef struct _ECellDateEditValue ECellDateEditValue;
struct _ECellDateEditValue {
@@ -60,7 +60,7 @@ typedef struct {
ECellTextClass parent_class;
} ECellDateEditTextClass;
-GtkType e_cell_date_edit_text_get_type (void);
+GType e_cell_date_edit_text_get_type (void);
ECell *e_cell_date_edit_text_new (const char *fontname,
GtkJustification justify);
diff --git a/calendar/gui/e-date-edit-config.h b/calendar/gui/e-date-edit-config.h
index 1cff692461..3fa37675b9 100644
--- a/calendar/gui/e-date-edit-config.h
+++ b/calendar/gui/e-date-edit-config.h
@@ -27,9 +27,9 @@
G_BEGIN_DECLS
-#define E_DATE_EDIT_CONFIG(obj) GTK_CHECK_CAST (obj, e_date_edit_config_get_type (), EDateEditConfig)
-#define E_DATE_EDIT_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_date_edit_config_get_type (), EDateEditConfigClass)
-#define E_IS_DATE_EDIT_CONFIG(obj) GTK_CHECK_TYPE (obj, e_date_edit_config_get_type ())
+#define E_DATE_EDIT_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_date_edit_config_get_type (), EDateEditConfig)
+#define E_DATE_EDIT_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_date_edit_config_get_type (), EDateEditConfigClass)
+#define E_IS_DATE_EDIT_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_date_edit_config_get_type ())
typedef struct _EDateEditConfig EDateEditConfig;
typedef struct _EDateEditConfigClass EDateEditConfigClass;
diff --git a/calendar/gui/e-date-time-list.c b/calendar/gui/e-date-time-list.c
index 702219860a..18b9a6bdaf 100644
--- a/calendar/gui/e-date-time-list.c
+++ b/calendar/gui/e-date-time-list.c
@@ -73,7 +73,7 @@ static gboolean e_date_time_list_iter_parent (GtkTreeModel *tree_m
static GObjectClass *parent_class = NULL;
-GtkType
+GType
e_date_time_list_get_type (void)
{
static GType date_time_list_type = 0;
diff --git a/calendar/gui/e-date-time-list.h b/calendar/gui/e-date-time-list.h
index dc306e41b4..c893c111a9 100644
--- a/calendar/gui/e-date-time-list.h
+++ b/calendar/gui/e-date-time-list.h
@@ -29,11 +29,11 @@
G_BEGIN_DECLS
#define E_TYPE_DATE_TIME_LIST (e_date_time_list_get_type ())
-#define E_DATE_TIME_LIST(obj) (GTK_CHECK_CAST ((obj), E_TYPE_DATE_TIME_LIST, EDateTimeList))
-#define E_DATE_TIME_LIST_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), E_TYPE_DATE_TIME_LIST, EDateTimeListClass))
-#define E_IS_DATE_TIME_LIST(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_DATE_TIME_LIST))
-#define E_IS_DATE_TIME_LIST_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), E_TYPE_DATE_TIME_LIST))
-#define E_DATE_TIME_LIST_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), E_TYPE_DATE_TIME_LIST, EDateTimeListClass))
+#define E_DATE_TIME_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_DATE_TIME_LIST, EDateTimeList))
+#define E_DATE_TIME_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), E_TYPE_DATE_TIME_LIST, EDateTimeListClass))
+#define E_IS_DATE_TIME_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_DATE_TIME_LIST))
+#define E_IS_DATE_TIME_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_DATE_TIME_LIST))
+#define E_DATE_TIME_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), E_TYPE_DATE_TIME_LIST, EDateTimeListClass))
typedef struct _EDateTimeList EDateTimeList;
typedef struct _EDateTimeListClass EDateTimeListClass;
@@ -63,7 +63,7 @@ struct _EDateTimeListClass
GObjectClass parent_class;
};
-GtkType e_date_time_list_get_type (void);
+GType e_date_time_list_get_type (void);
EDateTimeList *e_date_time_list_new (void);
const ECalComponentDateTime *e_date_time_list_get_date_time (EDateTimeList *date_time_list,
diff --git a/calendar/gui/e-day-view-config.h b/calendar/gui/e-day-view-config.h
index 372d50262c..f9790df7c3 100644
--- a/calendar/gui/e-day-view-config.h
+++ b/calendar/gui/e-day-view-config.h
@@ -27,9 +27,9 @@
G_BEGIN_DECLS
-#define E_DAY_VIEW_CONFIG(obj) GTK_CHECK_CAST (obj, e_day_view_config_get_type (), EDayViewConfig)
-#define E_DAY_VIEW_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_day_view_config_get_type (), EDayViewConfigClass)
-#define E_IS_DAY_VIEW_CONFIG(obj) GTK_CHECK_TYPE (obj, e_day_view_config_get_type ())
+#define E_DAY_VIEW_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_day_view_config_get_type (), EDayViewConfig)
+#define E_DAY_VIEW_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_day_view_config_get_type (), EDayViewConfigClass)
+#define E_IS_DAY_VIEW_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_day_view_config_get_type ())
typedef struct _EDayViewConfig EDayViewConfig;
typedef struct _EDayViewConfigClass EDayViewConfigClass;
diff --git a/calendar/gui/e-day-view-main-item.c b/calendar/gui/e-day-view-main-item.c
index ca14210233..9e94bb3cdc 100644
--- a/calendar/gui/e-day-view-main-item.c
+++ b/calendar/gui/e-day-view-main-item.c
@@ -40,8 +40,10 @@
#include <libecal/e-cal-time-util.h>
#include <e-calendar-view.h>
-static void e_day_view_main_item_set_arg (GtkObject *o, GtkArg *arg ,
- guint arg_id);
+static void e_day_view_main_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec);
static void e_day_view_main_item_update (GnomeCanvasItem *item,
double *affine,
ArtSVP *clip_path, int flags);
@@ -80,8 +82,8 @@ static void e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
/* The arguments we take */
enum {
- ARG_0,
- ARG_DAY_VIEW
+ PROP_0,
+ PROP_DAY_VIEW
};
G_DEFINE_TYPE (EDayViewMainItem, e_day_view_main_item, GNOME_TYPE_CANVAS_ITEM)
@@ -89,23 +91,26 @@ G_DEFINE_TYPE (EDayViewMainItem, e_day_view_main_item, GNOME_TYPE_CANVAS_ITEM)
static void
e_day_view_main_item_class_init (EDayViewMainItemClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
- object_class = (GtkObjectClass *) class;
- item_class = (GnomeCanvasItemClass *) class;
+ object_class = G_OBJECT_CLASS (class);
+ object_class->set_property = e_day_view_main_item_set_property;
- gtk_object_add_arg_type ("EDayViewMainItem::day_view",
- GTK_TYPE_POINTER, GTK_ARG_WRITABLE,
- ARG_DAY_VIEW);
+ item_class = GNOME_CANVAS_ITEM_CLASS (class);
+ item_class->update = e_day_view_main_item_update;
+ item_class->draw = e_day_view_main_item_draw;
+ item_class->point = e_day_view_main_item_point;
+ item_class->event = e_day_view_main_item_event;
- object_class->set_arg = e_day_view_main_item_set_arg;
-
- /* GnomeCanvasItem method overrides */
- item_class->update = e_day_view_main_item_update;
- item_class->draw = e_day_view_main_item_draw;
- item_class->point = e_day_view_main_item_point;
- item_class->event = e_day_view_main_item_event;
+ g_object_class_install_property (
+ object_class,
+ PROP_DAY_VIEW,
+ g_param_spec_pointer (
+ "day_view",
+ NULL,
+ NULL,
+ G_PARAM_WRITABLE));
/* init the accessibility support for e_day_view */
e_day_view_main_item_a11y_init ();
@@ -120,17 +125,22 @@ e_day_view_main_item_init (EDayViewMainItem *dvtitem)
static void
-e_day_view_main_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
+e_day_view_main_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
EDayViewMainItem *dvmitem;
- dvmitem = E_DAY_VIEW_MAIN_ITEM (o);
+ dvmitem = E_DAY_VIEW_MAIN_ITEM (object);
- switch (arg_id){
- case ARG_DAY_VIEW:
- dvmitem->day_view = GTK_VALUE_POINTER (*arg);
- break;
+ switch (property_id) {
+ case PROP_DAY_VIEW:
+ dvmitem->day_view = g_value_get_pointer (value);
+ return;
}
+
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
diff --git a/calendar/gui/e-day-view-main-item.h b/calendar/gui/e-day-view-main-item.h
index 7e64cb5927..335fc7e861 100644
--- a/calendar/gui/e-day-view-main-item.h
+++ b/calendar/gui/e-day-view-main-item.h
@@ -35,11 +35,11 @@ extern "C" {
* data in the main Day/Work Week display.
*/
-#define E_DAY_VIEW_MAIN_ITEM(obj) (GTK_CHECK_CAST((obj), \
+#define E_DAY_VIEW_MAIN_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \
e_day_view_main_item_get_type (), EDayViewMainItem))
-#define E_DAY_VIEW_MAIN_ITEM_CLASS(k) (GTK_CHECK_CLASS_CAST ((k),\
+#define E_DAY_VIEW_MAIN_ITEM_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k),\
e_day_view_main_item_get_type ()))
-#define E_IS_DAY_VIEW_MAIN_ITEM(o) (GTK_CHECK_TYPE((o), \
+#define E_IS_DAY_VIEW_MAIN_ITEM(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), \
e_day_view_main_item_get_type ()))
typedef struct {
@@ -55,7 +55,7 @@ typedef struct {
} EDayViewMainItemClass;
-GtkType e_day_view_main_item_get_type (void);
+GType e_day_view_main_item_get_type (void);
#ifdef __cplusplus
diff --git a/calendar/gui/e-day-view-time-item.c b/calendar/gui/e-day-view-time-item.c
index bbd9471e1a..6be8e34aaf 100644
--- a/calendar/gui/e-day-view-time-item.c
+++ b/calendar/gui/e-day-view-time-item.c
@@ -63,9 +63,10 @@
#define E_DVTMI_LARGE_HOUR_Y_PAD 1
#define E_DVTMI_SMALL_FONT_Y_PAD 1
-static void e_day_view_time_item_set_arg (GtkObject *o,
- GtkArg *arg,
- guint arg_id);
+static void e_day_view_time_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec);
static void e_day_view_time_item_update (GnomeCanvasItem *item,
double *affine,
@@ -99,8 +100,8 @@ static gint e_day_view_time_item_convert_position_to_row (EDayViewTimeItem *dvtm
/* The arguments we take */
enum {
- ARG_0,
- ARG_DAY_VIEW
+ PROP_0,
+ PROP_DAY_VIEW
};
G_DEFINE_TYPE (EDayViewTimeItem, e_day_view_time_item, GNOME_TYPE_CANVAS_ITEM)
@@ -108,23 +109,26 @@ G_DEFINE_TYPE (EDayViewTimeItem, e_day_view_time_item, GNOME_TYPE_CANVAS_ITEM)
static void
e_day_view_time_item_class_init (EDayViewTimeItemClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
- object_class = (GtkObjectClass *) class;
- item_class = (GnomeCanvasItemClass *) class;
-
- gtk_object_add_arg_type ("EDayViewTimeItem::day_view",
- GTK_TYPE_POINTER, GTK_ARG_WRITABLE,
- ARG_DAY_VIEW);
-
- object_class->set_arg = e_day_view_time_item_set_arg;
-
- /* GnomeCanvasItem method overrides */
- item_class->update = e_day_view_time_item_update;
- item_class->draw = e_day_view_time_item_draw;
- item_class->point = e_day_view_time_item_point;
- item_class->event = e_day_view_time_item_event;
+ object_class = G_OBJECT_CLASS (class);
+ object_class->set_property = e_day_view_time_item_set_property;
+
+ item_class = GNOME_CANVAS_ITEM_CLASS (class);
+ item_class->update = e_day_view_time_item_update;
+ item_class->draw = e_day_view_time_item_draw;
+ item_class->point = e_day_view_time_item_point;
+ item_class->event = e_day_view_time_item_event;
+
+ g_object_class_install_property (
+ object_class,
+ PROP_DAY_VIEW,
+ g_param_spec_pointer (
+ "day_view",
+ NULL,
+ NULL,
+ G_PARAM_WRITABLE));
}
@@ -136,17 +140,22 @@ e_day_view_time_item_init (EDayViewTimeItem *dvtmitem)
static void
-e_day_view_time_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
+e_day_view_time_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
EDayViewTimeItem *dvtmitem;
- dvtmitem = E_DAY_VIEW_TIME_ITEM (o);
+ dvtmitem = E_DAY_VIEW_TIME_ITEM (object);
- switch (arg_id){
- case ARG_DAY_VIEW:
- dvtmitem->day_view = GTK_VALUE_POINTER (*arg);
- break;
+ switch (property_id) {
+ case PROP_DAY_VIEW:
+ dvtmitem->day_view = g_value_get_pointer (value);
+ return;
}
+
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
diff --git a/calendar/gui/e-day-view-time-item.h b/calendar/gui/e-day-view-time-item.h
index b897eb26f0..f47935190d 100644
--- a/calendar/gui/e-day-view-time-item.h
+++ b/calendar/gui/e-day-view-time-item.h
@@ -35,11 +35,11 @@ extern "C" {
* the EDayView.
*/
-#define E_DAY_VIEW_TIME_ITEM(obj) (GTK_CHECK_CAST((obj), \
+#define E_DAY_VIEW_TIME_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \
e_day_view_time_item_get_type (), EDayViewTimeItem))
-#define E_DAY_VIEW_TIME_ITEM_CLASS(k) (GTK_CHECK_CLASS_CAST ((k),\
+#define E_DAY_VIEW_TIME_ITEM_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k),\
e_day_view_time_item_get_type ()))
-#define E_IS_DAY_VIEW_TIME_ITEM(o) (GTK_CHECK_TYPE((o), \
+#define E_IS_DAY_VIEW_TIME_ITEM(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), \
e_day_view_time_item_get_type ()))
typedef struct {
@@ -61,7 +61,7 @@ typedef struct {
} EDayViewTimeItemClass;
-GtkType e_day_view_time_item_get_type (void);
+GType e_day_view_time_item_get_type (void);
gint e_day_view_time_item_get_column_width (EDayViewTimeItem *dvtmitem);
diff --git a/calendar/gui/e-day-view-top-item.c b/calendar/gui/e-day-view-top-item.c
index e19ef570e6..bdfe58f734 100644
--- a/calendar/gui/e-day-view-top-item.c
+++ b/calendar/gui/e-day-view-top-item.c
@@ -37,9 +37,10 @@
#include "e-calendar-view.h"
#include "e-day-view-top-item.h"
-static void e_day_view_top_item_set_arg (GtkObject *o,
- GtkArg *arg,
- guint arg_id);
+static void e_day_view_top_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec);
static void e_day_view_top_item_update (GnomeCanvasItem *item,
double *affine,
ArtSVP *clip_path,
@@ -76,9 +77,9 @@ static gint e_day_view_top_item_event (GnomeCanvasItem *item,
/* The arguments we take */
enum {
- ARG_0,
- ARG_DAY_VIEW,
- ARG_SHOW_DATES
+ PROP_0,
+ PROP_DAY_VIEW,
+ PROP_SHOW_DATES
};
G_DEFINE_TYPE (EDayViewTopItem, e_day_view_top_item, GNOME_TYPE_CANVAS_ITEM)
@@ -86,27 +87,36 @@ G_DEFINE_TYPE (EDayViewTopItem, e_day_view_top_item, GNOME_TYPE_CANVAS_ITEM)
static void
e_day_view_top_item_class_init (EDayViewTopItemClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
- object_class = (GtkObjectClass *) class;
- item_class = (GnomeCanvasItemClass *) class;
-
- gtk_object_add_arg_type ("EDayViewTopItem::day_view",
- GTK_TYPE_POINTER, GTK_ARG_WRITABLE,
- ARG_DAY_VIEW);
-
- gtk_object_add_arg_type ("EDayViewTopItem::show_dates",
- GTK_TYPE_BOOL, GTK_ARG_WRITABLE,
- ARG_SHOW_DATES);
-
- object_class->set_arg = e_day_view_top_item_set_arg;
-
- /* GnomeCanvasItem method overrides */
- item_class->update = e_day_view_top_item_update;
- item_class->draw = e_day_view_top_item_draw;
- item_class->point = e_day_view_top_item_point;
- item_class->event = e_day_view_top_item_event;
+ object_class = G_OBJECT_CLASS (class);
+ object_class->set_property = e_day_view_top_item_set_property;
+
+ item_class = GNOME_CANVAS_ITEM_CLASS (class);
+ item_class->update = e_day_view_top_item_update;
+ item_class->draw = e_day_view_top_item_draw;
+ item_class->point = e_day_view_top_item_point;
+ item_class->event = e_day_view_top_item_event;
+
+ g_object_class_install_property (
+ object_class,
+ PROP_DAY_VIEW,
+ g_param_spec_pointer (
+ "day_view",
+ NULL,
+ NULL,
+ G_PARAM_WRITABLE));
+
+ g_object_class_install_property (
+ object_class,
+ PROP_SHOW_DATES,
+ g_param_spec_boolean (
+ "show_dates",
+ NULL,
+ NULL,
+ TRUE,
+ G_PARAM_WRITABLE));
}
@@ -119,20 +129,25 @@ e_day_view_top_item_init (EDayViewTopItem *dvtitem)
static void
-e_day_view_top_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
+e_day_view_top_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
EDayViewTopItem *dvtitem;
- dvtitem = E_DAY_VIEW_TOP_ITEM (o);
+ dvtitem = E_DAY_VIEW_TOP_ITEM (object);
- switch (arg_id){
- case ARG_DAY_VIEW:
- dvtitem->day_view = GTK_VALUE_POINTER (*arg);
- break;
- case ARG_SHOW_DATES:
- dvtitem->show_dates = GTK_VALUE_BOOL (*arg);
- break;
+ switch (property_id) {
+ case PROP_DAY_VIEW:
+ dvtitem->day_view = g_value_get_pointer (value);
+ return;
+ case PROP_SHOW_DATES:
+ dvtitem->show_dates = g_value_get_boolean (value);
+ return;
}
+
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
diff --git a/calendar/gui/e-day-view-top-item.h b/calendar/gui/e-day-view-top-item.h
index 2d21a42f35..3446cabcad 100644
--- a/calendar/gui/e-day-view-top-item.h
+++ b/calendar/gui/e-day-view-top-item.h
@@ -34,11 +34,11 @@ extern "C" {
* EDayViewTopItem - displays the top part of the Day/Work Week calendar view.
*/
-#define E_DAY_VIEW_TOP_ITEM(obj) (GTK_CHECK_CAST((obj), \
+#define E_DAY_VIEW_TOP_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \
e_day_view_top_item_get_type (), EDayViewTopItem))
-#define E_DAY_VIEW_TOP_ITEM_CLASS(k) (GTK_CHECK_CLASS_CAST ((k),\
+#define E_DAY_VIEW_TOP_ITEM_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k),\
e_day_view_top_item_get_type ()))
-#define E_IS_DAY_VIEW_TOP_ITEM(o) (GTK_CHECK_TYPE((o), \
+#define E_IS_DAY_VIEW_TOP_ITEM(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), \
e_day_view_top_item_get_type ()))
typedef struct {
@@ -57,7 +57,7 @@ typedef struct {
} EDayViewTopItemClass;
-GtkType e_day_view_top_item_get_type (void);
+GType e_day_view_top_item_get_type (void);
void e_day_view_top_item_get_day_label (EDayView *day_view, gint day,
gchar *buffer, gint buffer_len);
diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c
index c4cf1a2e4c..e33591acb7 100644
--- a/calendar/gui/e-day-view.c
+++ b/calendar/gui/e-day-view.c
@@ -3010,8 +3010,7 @@ e_day_view_on_long_event_button_press (EDayView *day_view,
} else if (event->type == GDK_2BUTTON_PRESS) {
e_day_view_on_event_double_click (day_view, -1,
event_num);
- gtk_signal_emit_stop_by_name (GTK_OBJECT (day_view->top_canvas),
- "button_press_event");
+ g_signal_stop_emission_by_name (day_view->top_canvas, "button_press_event");
return TRUE;
}
} else if (event->button == 3) {
@@ -3050,8 +3049,7 @@ e_day_view_on_event_button_press (EDayView *day_view,
e_day_view_on_event_double_click (day_view, day,
event_num);
- gtk_signal_emit_stop_by_name (GTK_OBJECT (day_view->main_canvas),
- "button_press_event");
+ g_signal_stop_emission_by_name (day_view->main_canvas, "button_press_event");
return TRUE;
}
} else if (event->button == 3) {
@@ -5776,12 +5774,11 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
/* Stop the signal last or we will also stop any
other events getting to the EText item. */
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item),
- "event");
+ g_signal_stop_emission_by_name (item, "event");
return TRUE;
} else if (event->key.keyval == GDK_Escape) {
cancel_editing (day_view);
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item), "event");
+ g_signal_stop_emission_by_name (item, "event");
/* focus should go to day view when stop editing */
gtk_widget_grab_focus (GTK_WIDGET (day_view));
return TRUE;
@@ -5816,8 +5813,7 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
tooltip_destroy (day_view, item);
/* Only let the EText handle the event while editing. */
if (!E_TEXT (item)->editing)
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item),
- "event");
+ g_signal_stop_emission_by_name (item, "event");
break;
case GDK_FOCUS_CHANGE:
if (event->focus_change.in)
diff --git a/calendar/gui/e-day-view.h b/calendar/gui/e-day-view.h
index b7fed463ca..b9fee2f250 100644
--- a/calendar/gui/e-day-view.h
+++ b/calendar/gui/e-day-view.h
@@ -182,9 +182,9 @@ struct _EDayViewEvent {
};
-#define E_DAY_VIEW(obj) GTK_CHECK_CAST (obj, e_day_view_get_type (), EDayView)
-#define E_DAY_VIEW_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_day_view_get_type (), EDayViewClass)
-#define E_IS_DAY_VIEW(obj) GTK_CHECK_TYPE (obj, e_day_view_get_type ())
+#define E_DAY_VIEW(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_day_view_get_type (), EDayView)
+#define E_DAY_VIEW_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_day_view_get_type (), EDayViewClass)
+#define E_IS_DAY_VIEW(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_day_view_get_type ())
typedef struct _EDayView EDayView;
@@ -474,7 +474,7 @@ struct _EDayViewClass
};
-GtkType e_day_view_get_type (void);
+GType e_day_view_get_type (void);
GtkWidget* e_day_view_new (void);
/* Whether we are displaying a work-week, in which case the display always
diff --git a/calendar/gui/e-itip-control.h b/calendar/gui/e-itip-control.h
index 82cc42376c..8e7cc74d63 100644
--- a/calendar/gui/e-itip-control.h
+++ b/calendar/gui/e-itip-control.h
@@ -28,10 +28,10 @@
G_BEGIN_DECLS
#define E_TYPE_ITIP_CONTROL (e_itip_control_get_type ())
-#define E_ITIP_CONTROL(obj) (GTK_CHECK_CAST ((obj), E_TYPE_ITIP_CONTROL, EItipControl))
-#define E_ITIP_CONTROL_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), E_TYPE_ITIP_CONTROL, EItipControlClass))
-#define E_IS_ITIP_CONTROL(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_ITIP_CONTROL))
-#define E_IS_ITIP_CONTROL_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((obj), E_TYPE_ITIP_CONTROL))
+#define E_ITIP_CONTROL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_ITIP_CONTROL, EItipControl))
+#define E_ITIP_CONTROL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), E_TYPE_ITIP_CONTROL, EItipControlClass))
+#define E_IS_ITIP_CONTROL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_ITIP_CONTROL))
+#define E_IS_ITIP_CONTROL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((obj), E_TYPE_ITIP_CONTROL))
typedef struct _EItipControl EItipControl;
@@ -50,7 +50,7 @@ struct _EItipControlClass {
-GtkType e_itip_control_get_type (void);
+GType e_itip_control_get_type (void);
GtkWidget * e_itip_control_new (void);
void e_itip_control_set_data (EItipControl *itip,
const gchar *text);
diff --git a/calendar/gui/e-meeting-time-sel-item.c b/calendar/gui/e-meeting-time-sel-item.c
index 211d4c71bd..fb2e637dc4 100644
--- a/calendar/gui/e-meeting-time-sel-item.c
+++ b/calendar/gui/e-meeting-time-sel-item.c
@@ -45,10 +45,12 @@
lines across the top of cells. */
#define E_MEETING_TIME_SELECTOR_DRAW_GRID_LINES_AT_BOTTOM 0
-static void e_meeting_time_selector_item_destroy (GtkObject *object);
+static void e_meeting_time_selector_item_dispose (GObject *object);
-static void e_meeting_time_selector_item_set_arg (GtkObject *o, GtkArg *arg,
- guint arg_id);
+static void e_meeting_time_selector_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec);
static void e_meeting_time_selector_item_realize (GnomeCanvasItem *item);
static void e_meeting_time_selector_item_unrealize (GnomeCanvasItem *item);
static void e_meeting_time_selector_item_update (GnomeCanvasItem *item,
@@ -96,35 +98,38 @@ static gboolean e_meeting_time_selector_item_calculate_busy_range (EMeetingTimeS
/* The arguments we take */
enum {
- ARG_0,
- ARG_MEETING_TIME_SELECTOR
+ PROP_0,
+ PROP_MEETING_TIME_SELECTOR
};
G_DEFINE_TYPE (EMeetingTimeSelectorItem, e_meeting_time_selector_item, GNOME_TYPE_CANVAS_ITEM)
static void
-e_meeting_time_selector_item_class_init (EMeetingTimeSelectorItemClass *mts_item_class)
+e_meeting_time_selector_item_class_init (EMeetingTimeSelectorItemClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
- object_class = (GtkObjectClass *) mts_item_class;
- item_class = (GnomeCanvasItemClass *) mts_item_class;
-
- gtk_object_add_arg_type ("EMeetingTimeSelectorItem::meeting_time_selector",
- GTK_TYPE_POINTER, GTK_ARG_WRITABLE,
- ARG_MEETING_TIME_SELECTOR);
-
- object_class->destroy = e_meeting_time_selector_item_destroy;
- object_class->set_arg = e_meeting_time_selector_item_set_arg;
-
- /* GnomeCanvasItem method overrides */
- item_class->realize = e_meeting_time_selector_item_realize;
- item_class->unrealize = e_meeting_time_selector_item_unrealize;
- item_class->update = e_meeting_time_selector_item_update;
- item_class->draw = e_meeting_time_selector_item_draw;
- item_class->point = e_meeting_time_selector_item_point;
- item_class->event = e_meeting_time_selector_item_event;
+ object_class = G_OBJECT_CLASS (class);
+ object_class->dispose = e_meeting_time_selector_item_dispose;
+ object_class->set_property = e_meeting_time_selector_item_set_property;
+
+ item_class = GNOME_CANVAS_ITEM_CLASS (class);
+ item_class->realize = e_meeting_time_selector_item_realize;
+ item_class->unrealize = e_meeting_time_selector_item_unrealize;
+ item_class->update = e_meeting_time_selector_item_update;
+ item_class->draw = e_meeting_time_selector_item_draw;
+ item_class->point = e_meeting_time_selector_item_point;
+ item_class->event = e_meeting_time_selector_item_event;
+
+ g_object_class_install_property (
+ object_class,
+ PROP_MEETING_TIME_SELECTOR,
+ g_param_spec_pointer (
+ "meeting_time_selector",
+ NULL,
+ NULL,
+ G_PARAM_WRITABLE));
}
@@ -152,7 +157,7 @@ e_meeting_time_selector_item_init (EMeetingTimeSelectorItem *mts_item)
static void
-e_meeting_time_selector_item_destroy (GtkObject *object)
+e_meeting_time_selector_item_dispose (GObject *object)
{
EMeetingTimeSelectorItem *mts_item;
@@ -171,23 +176,27 @@ e_meeting_time_selector_item_destroy (GtkObject *object)
mts_item->busy_cursor = NULL;
}
- if (GTK_OBJECT_CLASS (e_meeting_time_selector_item_parent_class)->destroy)
- (*GTK_OBJECT_CLASS (e_meeting_time_selector_item_parent_class)->destroy)(object);
+ G_OBJECT_CLASS (e_meeting_time_selector_item_parent_class)->dispose (object);
}
static void
-e_meeting_time_selector_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
+e_meeting_time_selector_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
EMeetingTimeSelectorItem *mts_item;
- mts_item = E_MEETING_TIME_SELECTOR_ITEM (o);
+ mts_item = E_MEETING_TIME_SELECTOR_ITEM (object);
- switch (arg_id){
- case ARG_MEETING_TIME_SELECTOR:
- mts_item->mts = GTK_VALUE_POINTER (*arg);
- break;
+ switch (property_id) {
+ case PROP_MEETING_TIME_SELECTOR:
+ mts_item->mts = g_value_get_pointer (value);
+ return;
}
+
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
diff --git a/calendar/gui/e-meeting-time-sel-item.h b/calendar/gui/e-meeting-time-sel-item.h
index 1ef96699d2..7746e9644a 100644
--- a/calendar/gui/e-meeting-time-sel-item.h
+++ b/calendar/gui/e-meeting-time-sel-item.h
@@ -38,9 +38,9 @@ extern "C" {
#endif /* __cplusplus */
-#define E_MEETING_TIME_SELECTOR_ITEM(obj) (GTK_CHECK_CAST((obj), e_meeting_time_selector_item_get_type (), EMeetingTimeSelectorItem))
-#define E_MEETING_TIME_SELECTOR_ITEM_CLASS(k) (GTK_CHECK_CLASS_CAST ((k), e_meeting_time_selector_item_get_type (), EMeetingTimeSelectorItemClass))
-#define IS_E_MEETING_TIME_SELECTOR_ITEM(o) (GTK_CHECK_TYPE((o), e_meeting_time_selector_item_get_type ()))
+#define E_MEETING_TIME_SELECTOR_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), e_meeting_time_selector_item_get_type (), EMeetingTimeSelectorItem))
+#define E_MEETING_TIME_SELECTOR_ITEM_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), e_meeting_time_selector_item_get_type (), EMeetingTimeSelectorItemClass))
+#define IS_E_MEETING_TIME_SELECTOR_ITEM(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), e_meeting_time_selector_item_get_type ()))
typedef struct _EMeetingTimeSelectorItem EMeetingTimeSelectorItem;
@@ -73,7 +73,7 @@ struct _EMeetingTimeSelectorItemClass
GnomeCanvasItemClass parent_class;
};
-GtkType e_meeting_time_selector_item_get_type (void);
+GType e_meeting_time_selector_item_get_type (void);
void e_meeting_time_selector_item_set_normal_cursor (EMeetingTimeSelectorItem *mts_item);
diff --git a/calendar/gui/e-meeting-time-sel.c b/calendar/gui/e-meeting-time-sel.c
index 4744ab2e74..213882fadd 100644
--- a/calendar/gui/e-meeting-time-sel.c
+++ b/calendar/gui/e-meeting-time-sel.c
@@ -224,12 +224,13 @@ e_meeting_time_selector_class_init (EMeetingTimeSelectorClass * klass)
widget_class = (GtkWidgetClass *) klass;
mts_signals [CHANGED] =
- gtk_signal_new ("changed", GTK_RUN_FIRST,
- G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (EMeetingTimeSelectorClass,
- changed),
- gtk_signal_default_marshaller,
- GTK_TYPE_NONE, 0);
+ g_signal_new ("changed",
+ G_TYPE_FROM_CLASS (object_class),
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (EMeetingTimeSelectorClass, changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
object_class->destroy = e_meeting_time_selector_destroy;
@@ -688,7 +689,7 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
e_meeting_time_selector_update_end_date_edit (mts);
e_meeting_time_selector_update_date_popup_menus (mts);
- gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
+ g_signal_emit (mts, mts_signals [CHANGED], 0);
}
@@ -707,7 +708,7 @@ e_meeting_time_selector_add_key_color (EMeetingTimeSelector * mts,
darea = gtk_drawing_area_new ();
gtk_box_pack_start (GTK_BOX (child_hbox), darea, FALSE, FALSE, 0);
- gtk_object_set_user_data (GTK_OBJECT (darea), mts);
+ g_object_set_data (G_OBJECT (darea), "data", mts);
gtk_widget_set_size_request (darea, 14, 14);
gtk_widget_show (darea);
@@ -730,7 +731,7 @@ e_meeting_time_selector_expose_key_color (GtkWidget *darea,
GdkGC *gc;
gint width, height;
- mts = gtk_object_get_user_data (GTK_OBJECT (darea));
+ mts = g_object_get_data (G_OBJECT (darea), "data");
gc = mts->color_key_gc;
width = darea->allocation.width;
height = darea->allocation.height;
@@ -1112,7 +1113,7 @@ e_meeting_time_selector_set_meeting_time (EMeetingTimeSelector *mts,
e_meeting_time_selector_update_start_date_edit (mts);
e_meeting_time_selector_update_end_date_edit (mts);
- gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
+ g_signal_emit (mts, mts_signals [CHANGED], 0);
return TRUE;
}
@@ -1240,7 +1241,7 @@ e_meeting_time_selector_refresh_cb (gpointer data)
if (mts->display_main != NULL)
gtk_widget_queue_draw (mts->display_main);
- gtk_object_unref (GTK_OBJECT (mts));
+ g_object_unref (GTK_OBJECT (mts));
return FALSE;
}
@@ -1273,9 +1274,9 @@ e_meeting_time_selector_refresh_free_busy (EMeetingTimeSelector *mts, int row, g
int i;
for (i = 0; i < e_meeting_store_count_actual_attendees (mts->model); i++)
- gtk_object_ref (GTK_OBJECT (mts));
+ g_object_ref (GTK_OBJECT (mts));
} else {
- gtk_object_ref (GTK_OBJECT (mts));
+ g_object_ref (GTK_OBJECT (mts));
}
if (all)
@@ -1671,7 +1672,7 @@ e_meeting_time_selector_autopick (EMeetingTimeSelector *mts,
e_meeting_time_selector_update_start_date_edit (mts);
e_meeting_time_selector_update_end_date_edit (mts);
- gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
+ g_signal_emit (mts, mts_signals [CHANGED], 0);
return;
}
@@ -2237,7 +2238,7 @@ e_meeting_time_selector_on_start_time_changed (GtkWidget *widget,
gtk_widget_queue_draw (mts->display_top);
gtk_widget_queue_draw (mts->display_main);
- gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
+ g_signal_emit (mts, mts_signals [CHANGED], 0);
}
@@ -2287,7 +2288,7 @@ e_meeting_time_selector_on_end_time_changed (GtkWidget *widget,
gtk_widget_queue_draw (mts->display_top);
gtk_widget_queue_draw (mts->display_main);
- gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
+ g_signal_emit (mts, mts_signals [CHANGED], 0);
}
@@ -2494,7 +2495,7 @@ e_meeting_time_selector_drag_meeting_time (EMeetingTimeSelector *mts,
if (set_both_times
|| mts->dragging_position == E_MEETING_TIME_SELECTOR_POS_END
|| mts->dragging_position == E_MEETING_TIME_SELECTOR_POS_START)
- gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
+ g_signal_emit (mts, mts_signals [CHANGED], 0);
}
@@ -2634,7 +2635,7 @@ e_meeting_time_selector_timeout_handler (gpointer data)
if (set_both_times
|| mts->dragging_position == E_MEETING_TIME_SELECTOR_POS_END
|| mts->dragging_position == E_MEETING_TIME_SELECTOR_POS_START)
- gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
+ g_signal_emit (mts, mts_signals [CHANGED], 0);
scroll:
/* Redraw the canvases. We freeze and thaw the layouts so that they
diff --git a/calendar/gui/e-meeting-time-sel.h b/calendar/gui/e-meeting-time-sel.h
index 8a10c04b7e..8adae67cb1 100644
--- a/calendar/gui/e-meeting-time-sel.h
+++ b/calendar/gui/e-meeting-time-sel.h
@@ -91,9 +91,9 @@ extern const gchar *EMeetingTimeSelectorHours[24];
extern const gchar *EMeetingTimeSelectorHours12[24];
-#define E_MEETING_TIME_SELECTOR(obj) GTK_CHECK_CAST (obj, e_meeting_time_selector_get_type (), EMeetingTimeSelector)
-#define E_MEETING_TIME_SELECTOR_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_meeting_time_selector_get_type (), EMeetingTimeSelectorClass)
-#define IS_E_MEETING_TIME_SELECTOR(obj) GTK_CHECK_TYPE (obj, e_meeting_time_selector_get_type ())
+#define E_MEETING_TIME_SELECTOR(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_meeting_time_selector_get_type (), EMeetingTimeSelector)
+#define E_MEETING_TIME_SELECTOR_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_meeting_time_selector_get_type (), EMeetingTimeSelectorClass)
+#define IS_E_MEETING_TIME_SELECTOR(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_meeting_time_selector_get_type ())
typedef struct _EMeetingTimeSelector EMeetingTimeSelector;
@@ -280,7 +280,7 @@ struct _EMeetingTimeSelectorClass
* know where the data is coming from. This is mainly just for testing for now.
*/
-GtkType e_meeting_time_selector_get_type (void);
+GType e_meeting_time_selector_get_type (void);
GtkWidget* e_meeting_time_selector_new (EMeetingStore *ems);
void e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *ems);
diff --git a/calendar/gui/e-memo-table-config.h b/calendar/gui/e-memo-table-config.h
index ce4006df48..988e2fbbce 100644
--- a/calendar/gui/e-memo-table-config.h
+++ b/calendar/gui/e-memo-table-config.h
@@ -28,9 +28,9 @@
G_BEGIN_DECLS
-#define E_MEMO_TABLE_CONFIG(obj) GTK_CHECK_CAST (obj, e_memo_table_config_get_type (), EMemoTableConfig)
-#define E_MEMO_TABLE_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_memo_table_config_get_type (), EMemoTableConfigClass)
-#define E_IS_MEMO_TABLE_CONFIG(obj) GTK_CHECK_TYPE (obj, e_memo_table_config_get_type ())
+#define E_MEMO_TABLE_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_memo_table_config_get_type (), EMemoTableConfig)
+#define E_MEMO_TABLE_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_memo_table_config_get_type (), EMemoTableConfigClass)
+#define E_IS_MEMO_TABLE_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_memo_table_config_get_type ())
typedef struct _EMemoTableConfig EMemoTableConfig;
typedef struct _EMemoTableConfigClass EMemoTableConfigClass;
diff --git a/calendar/gui/e-memo-table.h b/calendar/gui/e-memo-table.h
index 5ce2f03cbc..0c7e294366 100644
--- a/calendar/gui/e-memo-table.h
+++ b/calendar/gui/e-memo-table.h
@@ -39,9 +39,9 @@ G_BEGIN_DECLS
*/
-#define E_MEMO_TABLE(obj) GTK_CHECK_CAST (obj, e_memo_table_get_type (), EMemoTable)
-#define E_MEMO_TABLE_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_memo_table_get_type (), EMemoTableClass)
-#define E_IS_MEMO_TABLE(obj) GTK_CHECK_TYPE (obj, e_memo_table_get_type ())
+#define E_MEMO_TABLE(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_memo_table_get_type (), EMemoTable)
+#define E_MEMO_TABLE_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_memo_table_get_type (), EMemoTableClass)
+#define E_IS_MEMO_TABLE(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_memo_table_get_type ())
typedef struct _EMemoTable EMemoTable;
@@ -79,7 +79,7 @@ struct _EMemoTableClass {
};
-GtkType e_memo_table_get_type (void);
+GType e_memo_table_get_type (void);
GtkWidget* e_memo_table_new (void);
ECalModel *e_memo_table_get_model (EMemoTable *memo_table);
diff --git a/calendar/gui/e-memos.c b/calendar/gui/e-memos.c
index 019cf2ddaa..e8953e3c4d 100644
--- a/calendar/gui/e-memos.c
+++ b/calendar/gui/e-memos.c
@@ -170,8 +170,7 @@ table_selection_change_cb (ETable *etable, gpointer data)
memos = E_MEMOS (data);
n_selected = e_table_selected_count (etable);
- gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SELECTION_CHANGED],
- n_selected);
+ g_signal_emit (memos, e_memos_signals[SELECTION_CHANGED], 0, n_selected);
if (n_selected != 1)
e_cal_component_memo_preview_clear (E_CAL_COMPONENT_MEMO_PREVIEW (memos->priv->preview));
@@ -558,13 +557,14 @@ e_memos_class_init (EMemosClass *klass)
object_class = (GtkObjectClass *) klass;
e_memos_signals[SELECTION_CHANGED] =
- gtk_signal_new ("selection_changed",
- GTK_RUN_LAST,
- G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (EMemosClass, selection_changed),
- g_cclosure_marshal_VOID__INT,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_INT);
+ g_signal_new ("selection_changed",
+ G_TYPE_FROM_CLASS (object_class),
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (EMemosClass, selection_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__INT,
+ G_TYPE_NONE, 1,
+ G_TYPE_INT);
e_memos_signals[SOURCE_ADDED] =
g_signal_new ("source_added",
@@ -781,7 +781,7 @@ backend_died_cb (ECal *client, gpointer data)
priv->clients_list = g_list_remove (priv->clients_list, client);
g_hash_table_remove (priv->clients, e_source_peek_uid (source));
- gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SOURCE_REMOVED], source);
+ g_signal_emit (memos, e_memos_signals[SOURCE_REMOVED], 0, source);
e_memo_table_set_status_message (E_MEMO_TABLE (e_memos_get_calendar_table (memos)), NULL);
@@ -830,7 +830,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, EMemos *memos)
/* Do this last because it unrefs the client */
g_hash_table_remove (priv->clients, e_source_peek_uid (source));
- gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SOURCE_REMOVED], source);
+ g_signal_emit (memos, e_memos_signals[SOURCE_REMOVED], 0, source);
set_status_message (memos, NULL);
g_object_unref (source);
@@ -872,7 +872,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, EMemos *memos)
/* Do this last because it unrefs the client */
g_hash_table_remove (priv->clients, e_source_peek_uid (source));
- gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SOURCE_REMOVED], source);
+ g_signal_emit (memos, e_memos_signals[SOURCE_REMOVED], 0, source);
set_status_message (memos, NULL);
g_object_unref (priv->default_client);
@@ -956,7 +956,7 @@ e_memos_add_memo_source (EMemos *memos, ESource *source)
g_hash_table_insert (priv->clients, g_strdup (uid) , client);
priv->clients_list = g_list_prepend (priv->clients_list, client);
- gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SOURCE_ADDED], source);
+ g_signal_emit (memos, e_memos_signals[SOURCE_ADDED], 0, source);
open_ecal (memos, client, FALSE, client_cal_opened_cb);
@@ -993,7 +993,7 @@ e_memos_remove_memo_source (EMemos *memos, ESource *source)
g_hash_table_remove (priv->clients, uid);
- gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SOURCE_REMOVED], source);
+ g_signal_emit (memos, e_memos_signals[SOURCE_REMOVED], 0, source);
return TRUE;
}
diff --git a/calendar/gui/e-memos.h b/calendar/gui/e-memos.h
index a6b17fc75f..d91773f4e2 100644
--- a/calendar/gui/e-memos.h
+++ b/calendar/gui/e-memos.h
@@ -33,11 +33,11 @@
#include "e-memo-table.h"
#define E_TYPE_MEMOS (e_memos_get_type ())
-#define E_MEMOS(obj) (GTK_CHECK_CAST ((obj), E_TYPE_MEMOS, EMemos))
-#define E_MEMOS_CLASS(klass) (GTK_CHECK_CAST_CLASS ((klass), E_TYPE_MEMOS, \
+#define E_MEMOS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_MEMOS, EMemos))
+#define E_MEMOS_CLASS(klass) (G_TYPE_CHECK_INSTANCE_CAST_CLASS ((klass), E_TYPE_MEMOS, \
EMemosClass))
-#define E_IS_MEMOS(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_MEMOS))
-#define E_IS_MEMOS_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), E_TYPE_MEMOS))
+#define E_IS_MEMOS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_MEMOS))
+#define E_IS_MEMOS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_MEMOS))
typedef struct _EMemos EMemos;
typedef struct _EMemosClass EMemosClass;
@@ -60,7 +60,7 @@ struct _EMemosClass {
};
-GtkType e_memos_get_type (void);
+GType e_memos_get_type (void);
GtkWidget *e_memos_construct (EMemos *memos);
GtkWidget *e_memos_new (void);
diff --git a/calendar/gui/e-mini-calendar-config.h b/calendar/gui/e-mini-calendar-config.h
index de252cdf25..1fc7529ea5 100644
--- a/calendar/gui/e-mini-calendar-config.h
+++ b/calendar/gui/e-mini-calendar-config.h
@@ -27,9 +27,9 @@
G_BEGIN_DECLS
-#define E_MINI_CALENDAR_CONFIG(obj) GTK_CHECK_CAST (obj, e_mini_calendar_config_get_type (), EMiniCalendarConfig)
-#define E_MINI_CALENDAR_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_mini_calendar_config_get_type (), EMiniCalendarConfigClass)
-#define E_IS_MINI_CALENDAR_CONFIG(obj) GTK_CHECK_TYPE (obj, e_mini_calendar_config_get_type ())
+#define E_MINI_CALENDAR_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_mini_calendar_config_get_type (), EMiniCalendarConfig)
+#define E_MINI_CALENDAR_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_mini_calendar_config_get_type (), EMiniCalendarConfigClass)
+#define E_IS_MINI_CALENDAR_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_mini_calendar_config_get_type ())
typedef struct _EMiniCalendarConfig EMiniCalendarConfig;
typedef struct _EMiniCalendarConfigClass EMiniCalendarConfigClass;
diff --git a/calendar/gui/e-tasks.c b/calendar/gui/e-tasks.c
index eae255bd88..b63d015eec 100644
--- a/calendar/gui/e-tasks.c
+++ b/calendar/gui/e-tasks.c
@@ -184,8 +184,7 @@ table_selection_change_cb (ETable *etable, gpointer data)
tasks = E_TASKS (data);
n_selected = e_table_selected_count (etable);
- gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SELECTION_CHANGED],
- n_selected);
+ g_signal_emit (tasks, e_tasks_signals[SELECTION_CHANGED], 0, n_selected);
if (n_selected != 1)
e_cal_component_preview_clear (E_CAL_COMPONENT_PREVIEW (tasks->priv->preview));
@@ -702,13 +701,14 @@ e_tasks_class_init (ETasksClass *class)
object_class = (GtkObjectClass *) class;
e_tasks_signals[SELECTION_CHANGED] =
- gtk_signal_new ("selection_changed",
- GTK_RUN_LAST,
- G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (ETasksClass, selection_changed),
- g_cclosure_marshal_VOID__INT,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_INT);
+ g_signal_new ("selection_changed",
+ G_TYPE_FROM_CLASS (object_class),
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (ETasksClass, selection_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__INT,
+ G_TYPE_NONE, 1,
+ G_TYPE_INT);
e_tasks_signals[SOURCE_ADDED] =
g_signal_new ("source_added",
@@ -932,7 +932,7 @@ backend_died_cb (ECal *client, gpointer data)
priv->clients_list = g_list_remove (priv->clients_list, client);
g_hash_table_remove (priv->clients, e_source_peek_uid (source));
- gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SOURCE_REMOVED], source);
+ g_signal_emit (tasks, e_tasks_signals[SOURCE_REMOVED], 0, source);
e_calendar_table_set_status_message (E_CALENDAR_TABLE (e_tasks_get_calendar_table (tasks)), NULL, -1);
@@ -982,7 +982,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, ETasks *tasks)
/* Do this last because it unrefs the client */
g_hash_table_remove (priv->clients, e_source_peek_uid (source));
- gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SOURCE_REMOVED], source);
+ g_signal_emit (tasks, e_tasks_signals[SOURCE_REMOVED], 0, source);
set_status_message (tasks, NULL);
g_object_unref (source);
@@ -1026,7 +1026,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, ETasks *tasks)
/* Do this last because it unrefs the client */
g_hash_table_remove (priv->clients, e_source_peek_uid (source));
- gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SOURCE_REMOVED], source);
+ g_signal_emit (tasks, e_tasks_signals[SOURCE_REMOVED], 0, source);
set_status_message (tasks, NULL);
g_object_unref (priv->default_client);
@@ -1192,7 +1192,7 @@ e_tasks_add_todo_source (ETasks *tasks, ESource *source)
g_hash_table_insert (priv->clients, g_strdup (uid) , client);
priv->clients_list = g_list_prepend (priv->clients_list, client);
- gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SOURCE_ADDED], source);
+ g_signal_emit (tasks, e_tasks_signals[SOURCE_ADDED], 0, source);
open_ecal (tasks, client, FALSE, client_cal_opened_cb);
@@ -1229,7 +1229,7 @@ e_tasks_remove_todo_source (ETasks *tasks, ESource *source)
g_hash_table_remove (priv->clients, uid);
- gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SOURCE_REMOVED], source);
+ g_signal_emit (tasks, e_tasks_signals[SOURCE_REMOVED], 0, source);
return TRUE;
}
diff --git a/calendar/gui/e-tasks.h b/calendar/gui/e-tasks.h
index 40503b86f3..69464b05b8 100644
--- a/calendar/gui/e-tasks.h
+++ b/calendar/gui/e-tasks.h
@@ -32,11 +32,11 @@
#include "e-calendar-table.h"
#define E_TYPE_TASKS (e_tasks_get_type ())
-#define E_TASKS(obj) (GTK_CHECK_CAST ((obj), E_TYPE_TASKS, ETasks))
-#define E_TASKS_CLASS(klass) (GTK_CHECK_CAST_CLASS ((klass), E_TYPE_TASKS, \
+#define E_TASKS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_TASKS, ETasks))
+#define E_TASKS_CLASS(klass) (G_TYPE_CHECK_INSTANCE_CAST_CLASS ((klass), E_TYPE_TASKS, \
ETasksClass))
-#define E_IS_TASKS(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_TASKS))
-#define E_IS_TASKS_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), E_TYPE_TASKS))
+#define E_IS_TASKS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_TASKS))
+#define E_IS_TASKS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_TASKS))
typedef struct _ETasks ETasks;
typedef struct _ETasksClass ETasksClass;
@@ -59,7 +59,7 @@ struct _ETasksClass {
};
-GtkType e_tasks_get_type (void);
+GType e_tasks_get_type (void);
GtkWidget *e_tasks_construct (ETasks *tasks);
GtkWidget *e_tasks_new (void);
diff --git a/calendar/gui/e-timezone-entry.c b/calendar/gui/e-timezone-entry.c
index 86f8b81261..53e5ed482b 100644
--- a/calendar/gui/e-timezone-entry.c
+++ b/calendar/gui/e-timezone-entry.c
@@ -92,14 +92,13 @@ e_timezone_entry_class_init (ETimezoneEntryClass *class)
widget_class->mnemonic_activate = e_timezone_entry_mnemonic_activate;
widget_class->focus = e_timezone_entry_focus;
timezone_entry_signals[CHANGED] =
- gtk_signal_new ("changed",
- GTK_RUN_LAST,
- G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (ETimezoneEntryClass,
- changed),
- gtk_marshal_NONE__NONE,
- GTK_TYPE_NONE, 0);
-
+ g_signal_new ("changed",
+ G_TYPE_FROM_CLASS (object_class),
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (ETimezoneEntryClass, changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
object_class->destroy = e_timezone_entry_destroy;
@@ -210,7 +209,7 @@ static void
on_entry_changed (GtkEntry *entry,
ETimezoneEntry *tentry)
{
- gtk_signal_emit (GTK_OBJECT (tentry), timezone_entry_signals[CHANGED]);
+ g_signal_emit (GTK_OBJECT (tentry), timezone_entry_signals[CHANGED], 0);
}
diff --git a/calendar/gui/e-timezone-entry.h b/calendar/gui/e-timezone-entry.h
index 3593b59008..bc35dbacc9 100644
--- a/calendar/gui/e-timezone-entry.h
+++ b/calendar/gui/e-timezone-entry.h
@@ -39,10 +39,10 @@ G_BEGIN_DECLS
#define E_TYPE_TIMEZONE_ENTRY (e_timezone_entry_get_type ())
-#define E_TIMEZONE_ENTRY(obj) (GTK_CHECK_CAST ((obj), E_TYPE_TIMEZONE_ENTRY, ETimezoneEntry))
-#define E_TIMEZONE_ENTRY_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), E_TYPE_TIMEZONE_ENTRY, ETimezoneEntryClass))
-#define E_IS_TIMEZONE_ENTRY(obj) (GTK_CHECK_TYPE ((obj), E_TYPE_TIMEZONE_ENTRY))
-#define E_IS_TIMEZONE_ENTRY_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), E_TYPE_TIMEZONE_ENTRY))
+#define E_TIMEZONE_ENTRY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), E_TYPE_TIMEZONE_ENTRY, ETimezoneEntry))
+#define E_TIMEZONE_ENTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), E_TYPE_TIMEZONE_ENTRY, ETimezoneEntryClass))
+#define E_IS_TIMEZONE_ENTRY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), E_TYPE_TIMEZONE_ENTRY))
+#define E_IS_TIMEZONE_ENTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), E_TYPE_TIMEZONE_ENTRY))
typedef struct _ETimezoneEntry ETimezoneEntry;
diff --git a/calendar/gui/e-week-view-config.h b/calendar/gui/e-week-view-config.h
index f79679837c..ed2e518613 100644
--- a/calendar/gui/e-week-view-config.h
+++ b/calendar/gui/e-week-view-config.h
@@ -27,9 +27,9 @@
G_BEGIN_DECLS
-#define E_WEEK_VIEW_CONFIG(obj) GTK_CHECK_CAST (obj, e_week_view_config_get_type (), EWeekViewConfig)
-#define E_WEEK_VIEW_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_week_view_config_get_type (), EWeekViewConfigClass)
-#define E_IS_WEEK_VIEW_CONFIG(obj) GTK_CHECK_TYPE (obj, e_week_view_config_get_type ())
+#define E_WEEK_VIEW_CONFIG(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_week_view_config_get_type (), EWeekViewConfig)
+#define E_WEEK_VIEW_CONFIG_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_week_view_config_get_type (), EWeekViewConfigClass)
+#define E_IS_WEEK_VIEW_CONFIG(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_week_view_config_get_type ())
typedef struct _EWeekViewConfig EWeekViewConfig;
typedef struct _EWeekViewConfigClass EWeekViewConfigClass;
diff --git a/calendar/gui/e-week-view-event-item.c b/calendar/gui/e-week-view-event-item.c
index 1a0abec167..0efeef27ee 100644
--- a/calendar/gui/e-week-view-event-item.c
+++ b/calendar/gui/e-week-view-event-item.c
@@ -41,9 +41,10 @@
#include <text/e-text.h>
-static void e_week_view_event_item_set_arg (GtkObject *o,
- GtkArg *arg,
- guint arg_id);
+static void e_week_view_event_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec);
static void e_week_view_event_item_update (GnomeCanvasItem *item,
double *affine,
ArtSVP *clip_path,
@@ -93,9 +94,9 @@ static ECalendarViewPosition e_week_view_event_item_get_position (EWeekViewEvent
/* The arguments we take */
enum {
- ARG_0,
- ARG_EVENT_NUM,
- ARG_SPAN_NUM
+ PROP_0,
+ PROP_EVENT_NUM,
+ PROP_SPAN_NUM
};
G_DEFINE_TYPE (EWeekViewEventItem, e_week_view_event_item, GNOME_TYPE_CANVAS_ITEM)
@@ -103,26 +104,41 @@ G_DEFINE_TYPE (EWeekViewEventItem, e_week_view_event_item, GNOME_TYPE_CANVAS_ITE
static void
e_week_view_event_item_class_init (EWeekViewEventItemClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
- object_class = (GtkObjectClass *) class;
- item_class = (GnomeCanvasItemClass *) class;
-
- gtk_object_add_arg_type ("EWeekViewEventItem::event_num",
- GTK_TYPE_INT, GTK_ARG_WRITABLE,
- ARG_EVENT_NUM);
- gtk_object_add_arg_type ("EWeekViewEventItem::span_num",
- GTK_TYPE_INT, GTK_ARG_WRITABLE,
- ARG_SPAN_NUM);
-
- object_class->set_arg = e_week_view_event_item_set_arg;
-
- /* GnomeCanvasItem method overrides */
- item_class->update = e_week_view_event_item_update;
- item_class->draw = e_week_view_event_item_draw;
- item_class->point = e_week_view_event_item_point;
- item_class->event = e_week_view_event_item_event;
+ object_class = G_OBJECT_CLASS (class);
+ object_class->set_property = e_week_view_event_item_set_property;
+
+ item_class = GNOME_CANVAS_ITEM_CLASS (class);
+ item_class->update = e_week_view_event_item_update;
+ item_class->draw = e_week_view_event_item_draw;
+ item_class->point = e_week_view_event_item_point;
+ item_class->event = e_week_view_event_item_event;
+
+ g_object_class_install_property (
+ object_class,
+ PROP_EVENT_NUM,
+ g_param_spec_int (
+ "event_num",
+ NULL,
+ NULL,
+ G_MININT,
+ G_MAXINT,
+ -1,
+ G_PARAM_WRITABLE));
+
+ g_object_class_install_property (
+ object_class,
+ PROP_SPAN_NUM,
+ g_param_spec_int (
+ "span_num",
+ NULL,
+ NULL,
+ G_MININT,
+ G_MAXINT,
+ -1,
+ G_PARAM_WRITABLE));
}
@@ -135,28 +151,29 @@ e_week_view_event_item_init (EWeekViewEventItem *wveitem)
static void
-e_week_view_event_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
+e_week_view_event_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
GnomeCanvasItem *item;
EWeekViewEventItem *wveitem;
- gboolean needs_update = FALSE;
- item = GNOME_CANVAS_ITEM (o);
- wveitem = E_WEEK_VIEW_EVENT_ITEM (o);
+ item = GNOME_CANVAS_ITEM (object);
+ wveitem = E_WEEK_VIEW_EVENT_ITEM (object);
- switch (arg_id){
- case ARG_EVENT_NUM:
- wveitem->event_num = GTK_VALUE_INT (*arg);
- needs_update = TRUE;
- break;
- case ARG_SPAN_NUM:
- wveitem->span_num = GTK_VALUE_INT (*arg);
- needs_update = TRUE;
- break;
+ switch (property_id) {
+ case PROP_EVENT_NUM:
+ wveitem->event_num = g_value_get_int (value);
+ gnome_canvas_item_request_update (item);
+ return;
+ case PROP_SPAN_NUM:
+ wveitem->span_num = g_value_get_int (value);
+ gnome_canvas_item_request_update (item);
+ return;
}
- if (needs_update)
- gnome_canvas_item_request_update (item);
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
@@ -1021,8 +1038,7 @@ e_week_view_event_item_button_press (EWeekViewEventItem *wveitem,
e_week_view_show_popup_menu (week_view,
(GdkEventButton*) bevent,
wveitem->event_num);
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item->canvas),
- "button_press_event");
+ g_signal_stop_emission_by_name (item->canvas, "button_press_event");
return TRUE;
}
diff --git a/calendar/gui/e-week-view-event-item.h b/calendar/gui/e-week-view-event-item.h
index 59440ef291..2231f38e61 100644
--- a/calendar/gui/e-week-view-event-item.h
+++ b/calendar/gui/e-week-view-event-item.h
@@ -36,11 +36,11 @@ extern "C" {
* edit the text.
*/
-#define E_WEEK_VIEW_EVENT_ITEM(obj) (GTK_CHECK_CAST((obj), \
+#define E_WEEK_VIEW_EVENT_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \
e_week_view_event_item_get_type (), EWeekViewEventItem))
-#define E_WEEK_VIEW_EVENT_ITEM_CLASS(k) (GTK_CHECK_CLASS_CAST ((k),\
+#define E_WEEK_VIEW_EVENT_ITEM_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k),\
e_week_view_event_item_get_type ()))
-#define E_IS_WEEK_VIEW_EVENT_ITEM(o) (GTK_CHECK_TYPE((o), \
+#define E_IS_WEEK_VIEW_EVENT_ITEM(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), \
e_week_view_event_item_get_type ()))
typedef struct {
@@ -59,7 +59,7 @@ typedef struct {
} EWeekViewEventItemClass;
-GtkType e_week_view_event_item_get_type (void);
+GType e_week_view_event_item_get_type (void);
diff --git a/calendar/gui/e-week-view-main-item.c b/calendar/gui/e-week-view-main-item.c
index 1931e7c76c..f3ebdd306b 100644
--- a/calendar/gui/e-week-view-main-item.c
+++ b/calendar/gui/e-week-view-main-item.c
@@ -36,9 +36,10 @@
#include "e-week-view-main-item.h"
#include "ea-calendar.h"
-static void e_week_view_main_item_set_arg (GtkObject *o,
- GtkArg *arg,
- guint arg_id);
+static void e_week_view_main_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec);
static void e_week_view_main_item_update (GnomeCanvasItem *item,
double *affine,
ArtSVP *clip_path,
@@ -66,8 +67,8 @@ static double e_week_view_main_item_point (GnomeCanvasItem *item,
/* The arguments we take */
enum {
- ARG_0,
- ARG_WEEK_VIEW
+ PROP_0,
+ PROP_WEEK_VIEW
};
G_DEFINE_TYPE (EWeekViewMainItem, e_week_view_main_item, GNOME_TYPE_CANVAS_ITEM)
@@ -75,22 +76,25 @@ G_DEFINE_TYPE (EWeekViewMainItem, e_week_view_main_item, GNOME_TYPE_CANVAS_ITEM)
static void
e_week_view_main_item_class_init (EWeekViewMainItemClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
- object_class = (GtkObjectClass *) class;
- item_class = (GnomeCanvasItemClass *) class;
+ object_class = G_OBJECT_CLASS (class);
+ object_class->set_property = e_week_view_main_item_set_property;
- gtk_object_add_arg_type ("EWeekViewMainItem::week_view",
- GTK_TYPE_POINTER, GTK_ARG_WRITABLE,
- ARG_WEEK_VIEW);
+ item_class = GNOME_CANVAS_ITEM_CLASS (class);
+ item_class->update = e_week_view_main_item_update;
+ item_class->draw = e_week_view_main_item_draw;
+ item_class->point = e_week_view_main_item_point;
- object_class->set_arg = e_week_view_main_item_set_arg;
-
- /* GnomeCanvasItem method overrides */
- item_class->update = e_week_view_main_item_update;
- item_class->draw = e_week_view_main_item_draw;
- item_class->point = e_week_view_main_item_point;
+ g_object_class_install_property (
+ object_class,
+ PROP_WEEK_VIEW,
+ g_param_spec_pointer (
+ "week_view",
+ NULL,
+ NULL,
+ G_PARAM_WRITABLE));
/* init the accessibility support for e_week_view_main_item */
e_week_view_main_item_a11y_init ();
@@ -105,17 +109,22 @@ e_week_view_main_item_init (EWeekViewMainItem *wvmitem)
static void
-e_week_view_main_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
+e_week_view_main_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
EWeekViewMainItem *wvmitem;
- wvmitem = E_WEEK_VIEW_MAIN_ITEM (o);
+ wvmitem = E_WEEK_VIEW_MAIN_ITEM (object);
- switch (arg_id){
- case ARG_WEEK_VIEW:
- wvmitem->week_view = GTK_VALUE_POINTER (*arg);
- break;
+ switch (property_id) {
+ case PROP_WEEK_VIEW:
+ wvmitem->week_view = g_value_get_pointer (value);
+ return;
}
+
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
diff --git a/calendar/gui/e-week-view-main-item.h b/calendar/gui/e-week-view-main-item.h
index f475024051..f9e26cf0a9 100644
--- a/calendar/gui/e-week-view-main-item.h
+++ b/calendar/gui/e-week-view-main-item.h
@@ -35,11 +35,11 @@ extern "C" {
* Month calendar views.
*/
-#define E_WEEK_VIEW_MAIN_ITEM(obj) (GTK_CHECK_CAST((obj), \
+#define E_WEEK_VIEW_MAIN_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \
e_week_view_main_item_get_type (), EWeekViewMainItem))
-#define E_WEEK_VIEW_MAIN_ITEM_CLASS(k) (GTK_CHECK_CLASS_CAST ((k),\
+#define E_WEEK_VIEW_MAIN_ITEM_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k),\
e_week_view_main_item_get_type ()))
-#define E_IS_WEEK_VIEW_MAIN_ITEM(o) (GTK_CHECK_TYPE((o), \
+#define E_IS_WEEK_VIEW_MAIN_ITEM(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), \
e_week_view_main_item_get_type ()))
typedef struct {
@@ -55,7 +55,7 @@ typedef struct {
} EWeekViewMainItemClass;
-GtkType e_week_view_main_item_get_type (void);
+GType e_week_view_main_item_get_type (void);
diff --git a/calendar/gui/e-week-view-titles-item.c b/calendar/gui/e-week-view-titles-item.c
index ec8edcc780..a42d5f074e 100644
--- a/calendar/gui/e-week-view-titles-item.c
+++ b/calendar/gui/e-week-view-titles-item.c
@@ -34,9 +34,10 @@
#include <e-util/e-util.h>
#include "e-week-view-titles-item.h"
-static void e_week_view_titles_item_set_arg (GtkObject *o,
- GtkArg *arg,
- guint arg_id);
+static void e_week_view_titles_item_set_property(GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec);
static void e_week_view_titles_item_update (GnomeCanvasItem *item,
double *affine,
ArtSVP *clip_path,
@@ -56,8 +57,8 @@ static double e_week_view_titles_item_point (GnomeCanvasItem *item,
/* The arguments we take */
enum {
- ARG_0,
- ARG_WEEK_VIEW
+ PROP_0,
+ PROP_WEEK_VIEW
};
G_DEFINE_TYPE (EWeekViewTitlesItem, e_week_view_titles_item, GNOME_TYPE_CANVAS_ITEM)
@@ -65,22 +66,25 @@ G_DEFINE_TYPE (EWeekViewTitlesItem, e_week_view_titles_item, GNOME_TYPE_CANVAS_I
static void
e_week_view_titles_item_class_init (EWeekViewTitlesItemClass *class)
{
- GtkObjectClass *object_class;
+ GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
- object_class = (GtkObjectClass *) class;
- item_class = (GnomeCanvasItemClass *) class;
-
- gtk_object_add_arg_type ("EWeekViewTitlesItem::week_view",
- GTK_TYPE_POINTER, GTK_ARG_WRITABLE,
- ARG_WEEK_VIEW);
-
- object_class->set_arg = e_week_view_titles_item_set_arg;
-
- /* GnomeCanvasItem method overrides */
- item_class->update = e_week_view_titles_item_update;
- item_class->draw = e_week_view_titles_item_draw;
- item_class->point = e_week_view_titles_item_point;
+ object_class = G_OBJECT_CLASS (class);
+ object_class->set_property = e_week_view_titles_item_set_property;
+
+ item_class = GNOME_CANVAS_ITEM_CLASS (class);
+ item_class->update = e_week_view_titles_item_update;
+ item_class->draw = e_week_view_titles_item_draw;
+ item_class->point = e_week_view_titles_item_point;
+
+ g_object_class_install_property (
+ object_class,
+ PROP_WEEK_VIEW,
+ g_param_spec_pointer (
+ "week_view",
+ NULL,
+ NULL,
+ G_PARAM_WRITABLE));
}
@@ -92,17 +96,22 @@ e_week_view_titles_item_init (EWeekViewTitlesItem *wvtitem)
static void
-e_week_view_titles_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
+e_week_view_titles_item_set_property (GObject *object,
+ guint property_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
EWeekViewTitlesItem *wvtitem;
- wvtitem = E_WEEK_VIEW_TITLES_ITEM (o);
+ wvtitem = E_WEEK_VIEW_TITLES_ITEM (object);
- switch (arg_id){
- case ARG_WEEK_VIEW:
- wvtitem->week_view = GTK_VALUE_POINTER (*arg);
- break;
+ switch (property_id) {
+ case PROP_WEEK_VIEW:
+ wvtitem->week_view = g_value_get_pointer (value);
+ return;
}
+
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
}
diff --git a/calendar/gui/e-week-view-titles-item.h b/calendar/gui/e-week-view-titles-item.h
index e70193b14b..daa36240a9 100644
--- a/calendar/gui/e-week-view-titles-item.h
+++ b/calendar/gui/e-week-view-titles-item.h
@@ -35,11 +35,11 @@ extern "C" {
* the Month calendar view.
*/
-#define E_WEEK_VIEW_TITLES_ITEM(obj) (GTK_CHECK_CAST((obj), \
+#define E_WEEK_VIEW_TITLES_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \
e_week_view_titles_item_get_type (), EWeekViewTitlesItem))
-#define E_WEEK_VIEW_TITLES_ITEM_CLASS(k) (GTK_CHECK_CLASS_CAST ((k),\
+#define E_WEEK_VIEW_TITLES_ITEM_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k),\
e_week_view_titles_item_get_type ()))
-#define E_IS_WEEK_VIEW_TITLES_ITEM(o) (GTK_CHECK_TYPE((o), \
+#define E_IS_WEEK_VIEW_TITLES_ITEM(o) (G_TYPE_CHECK_INSTANCE_TYPE((o), \
e_week_view_titles_item_get_type ()))
typedef struct {
@@ -55,7 +55,7 @@ typedef struct {
} EWeekViewTitlesItemClass;
-GtkType e_week_view_titles_item_get_type (void);
+GType e_week_view_titles_item_get_type (void);
diff --git a/calendar/gui/e-week-view.c b/calendar/gui/e-week-view.c
index 53c2cd63ab..f8d53434e8 100644
--- a/calendar/gui/e-week-view.c
+++ b/calendar/gui/e-week-view.c
@@ -3088,12 +3088,11 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
/* Stop the signal last or we will also stop any
other events getting to the EText item. */
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item),
- "event");
+ g_signal_stop_emission_by_name (GTK_OBJECT (item), "event");
return TRUE;
} else if (gdkevent->key.keyval == GDK_Escape) {
cancel_editing (week_view);
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item), "event");
+ g_signal_stop_emission_by_name (GTK_OBJECT (item), "event");
/* focus should go to week view when stop editing */
gtk_widget_grab_focus (GTK_WIDGET (week_view));
return TRUE;
@@ -3111,7 +3110,7 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
event->comp_data->client,
event->comp_data->icalcomp, FALSE);
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item), "event");
+ g_signal_stop_emission_by_name (GTK_OBJECT (item), "event");
return TRUE;
case GDK_BUTTON_PRESS:
tooltip_destroy (week_view, item);
@@ -3139,8 +3138,8 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
(GdkEventButton*) gdkevent,
event_num);
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item->canvas),
- "button_press_event");
+ g_signal_stop_emission_by_name (GTK_OBJECT (item->canvas),
+ "button_press_event");
return TRUE;
}
@@ -3151,8 +3150,7 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
/* Only let the EText handle the event while editing. */
if (!E_TEXT (item)->editing) {
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item),
- "event");
+ g_signal_stop_emission_by_name (GTK_OBJECT (item), "event");
if (gdkevent) {
week_view->drag_event_x = gdkevent->button.x;
@@ -3187,8 +3185,7 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
/* Stop the signal last or we will also stop any
other events getting to the EText item. */
- gtk_signal_emit_stop_by_name (GTK_OBJECT (item),
- "event");
+ g_signal_stop_emission_by_name (GTK_OBJECT (item), "event");
return TRUE;
}
week_view->pressed_event_num = -1;
diff --git a/calendar/gui/e-week-view.h b/calendar/gui/e-week-view.h
index ca46060c37..4e2ea89564 100644
--- a/calendar/gui/e-week-view.h
+++ b/calendar/gui/e-week-view.h
@@ -149,9 +149,9 @@ struct _EWeekViewEvent {
};
-#define E_WEEK_VIEW(obj) GTK_CHECK_CAST (obj, e_week_view_get_type (), EWeekView)
-#define E_WEEK_VIEW_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_week_view_get_type (), EWeekViewClass)
-#define E_IS_WEEK_VIEW(obj) GTK_CHECK_TYPE (obj, e_week_view_get_type ())
+#define E_WEEK_VIEW(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, e_week_view_get_type (), EWeekView)
+#define E_WEEK_VIEW_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, e_week_view_get_type (), EWeekViewClass)
+#define E_IS_WEEK_VIEW(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, e_week_view_get_type ())
typedef struct _EWeekView EWeekView;
@@ -347,7 +347,7 @@ struct _EWeekViewClass
};
-GtkType e_week_view_get_type (void);
+GType e_week_view_get_type (void);
GtkWidget* e_week_view_new (void);
/* The first day shown. Note that it will be rounded down to the start of a
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c
index dfa066d0ba..561a0dc491 100644
--- a/calendar/gui/gnome-cal.c
+++ b/calendar/gui/gnome-cal.c
@@ -263,65 +263,71 @@ gnome_calendar_class_init (GnomeCalendarClass *class)
object_class = (GtkObjectClass *) class;
gnome_calendar_signals[DATES_SHOWN_CHANGED] =
- gtk_signal_new ("dates_shown_changed",
- GTK_RUN_LAST,
+ g_signal_new ("dates_shown_changed",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (GnomeCalendarClass,
- dates_shown_changed),
- gtk_marshal_NONE__NONE,
- GTK_TYPE_NONE, 0);
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (GnomeCalendarClass, dates_shown_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
gnome_calendar_signals[CALENDAR_SELECTION_CHANGED] =
- gtk_signal_new ("calendar_selection_changed",
- GTK_RUN_LAST,
+ g_signal_new ("calendar_selection_changed",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (GnomeCalendarClass, calendar_selection_changed),
- gtk_marshal_NONE__NONE,
- GTK_TYPE_NONE, 0);
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (GnomeCalendarClass, calendar_selection_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
gnome_calendar_signals[TASKPAD_SELECTION_CHANGED] =
- gtk_signal_new ("taskpad_selection_changed",
- GTK_RUN_LAST,
+ g_signal_new ("taskpad_selection_changed",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (GnomeCalendarClass, taskpad_selection_changed),
- gtk_marshal_NONE__NONE,
- GTK_TYPE_NONE, 0);
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (GnomeCalendarClass, taskpad_selection_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
gnome_calendar_signals[MEMOPAD_SELECTION_CHANGED] =
- gtk_signal_new ("memopad_selection_changed",
- GTK_RUN_LAST,
+ g_signal_new ("memopad_selection_changed",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (GnomeCalendarClass, memopad_selection_changed),
- gtk_marshal_NONE__NONE,
- GTK_TYPE_NONE, 0);
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (GnomeCalendarClass, memopad_selection_changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
gnome_calendar_signals[CALENDAR_FOCUS_CHANGE] =
- gtk_signal_new ("calendar_focus_change",
- GTK_RUN_FIRST,
+ g_signal_new ("calendar_focus_change",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (GnomeCalendarClass, calendar_focus_change),
- gtk_marshal_NONE__BOOL,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_BOOL);
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (GnomeCalendarClass, calendar_focus_change),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__BOOLEAN,
+ G_TYPE_NONE, 1,
+ G_TYPE_BOOLEAN);
gnome_calendar_signals[TASKPAD_FOCUS_CHANGE] =
- gtk_signal_new ("taskpad_focus_change",
- GTK_RUN_FIRST,
+ g_signal_new ("taskpad_focus_change",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (GnomeCalendarClass, taskpad_focus_change),
- gtk_marshal_NONE__BOOL,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_BOOL);
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (GnomeCalendarClass, taskpad_focus_change),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__BOOLEAN,
+ G_TYPE_NONE, 1,
+ G_TYPE_BOOLEAN);
gnome_calendar_signals[MEMOPAD_FOCUS_CHANGE] =
- gtk_signal_new ("memopad_focus_change",
- GTK_RUN_FIRST,
+ g_signal_new ("memopad_focus_change",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (GnomeCalendarClass, memopad_focus_change),
- gtk_marshal_NONE__BOOL,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_BOOL);
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (GnomeCalendarClass, memopad_focus_change),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__BOOLEAN,
+ G_TYPE_NONE, 1,
+ G_TYPE_BOOLEAN);
gnome_calendar_signals[SOURCE_ADDED] =
g_signal_new ("source_added",
@@ -994,8 +1000,7 @@ search_bar_category_changed_cb (CalSearchBar *cal_search, const char *category,
static void
view_selection_changed_cb (GtkWidget *view, GnomeCalendar *gcal)
{
- gtk_signal_emit (GTK_OBJECT (gcal),
- gnome_calendar_signals[CALENDAR_SELECTION_CHANGED]);
+ g_signal_emit (gcal, gnome_calendar_signals[CALENDAR_SELECTION_CHANGED], 0);
}
@@ -1050,8 +1055,8 @@ table_canvas_focus_change_cb (GtkWidget *widget, GdkEventFocus *event, gpointer
gcal = GNOME_CALENDAR (data);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals [TASKPAD_FOCUS_CHANGE],
- event->in ? TRUE : FALSE);
+ g_signal_emit (gcal, gnome_calendar_signals [TASKPAD_FOCUS_CHANGE], 0,
+ event->in ? TRUE : FALSE);
return FALSE;
}
@@ -1063,8 +1068,8 @@ memo_canvas_focus_change_cb (GtkWidget *widget, GdkEventFocus *event, gpointer d
gcal = GNOME_CALENDAR (data);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals [MEMOPAD_FOCUS_CHANGE],
- event->in ? TRUE : FALSE);
+ g_signal_emit (gcal, gnome_calendar_signals [MEMOPAD_FOCUS_CHANGE], 0,
+ event->in ? TRUE : FALSE);
return FALSE;
}
@@ -1076,8 +1081,8 @@ calendar_focus_change_cb (GtkWidget *widget, GdkEventFocus *event, gpointer data
gcal = GNOME_CALENDAR (data);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals [CALENDAR_FOCUS_CHANGE],
- event->in ? TRUE : FALSE);
+ g_signal_emit (gcal, gnome_calendar_signals [CALENDAR_FOCUS_CHANGE], 0,
+ event->in ? TRUE : FALSE);
return FALSE;
}
@@ -1133,7 +1138,7 @@ table_selection_change_cb (ETable *etable, gpointer data)
gcal = GNOME_CALENDAR (data);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[TASKPAD_SELECTION_CHANGED]);
+ g_signal_emit (gcal, gnome_calendar_signals[TASKPAD_SELECTION_CHANGED], 0);
}
static void
@@ -1143,7 +1148,7 @@ memo_selection_change_cb (ETable *etable, gpointer data)
gcal = GNOME_CALENDAR (data);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[MEMOPAD_SELECTION_CHANGED]);
+ g_signal_emit (gcal, gnome_calendar_signals[MEMOPAD_SELECTION_CHANGED], 0);
}
static void
@@ -2668,7 +2673,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
priv->clients_list[source_type] = g_list_remove (priv->clients_list[source_type], ecal);
g_hash_table_remove (priv->clients[source_type], e_source_peek_uid (source));
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
+ g_signal_emit (gcal, gnome_calendar_signals[SOURCE_REMOVED], 0, source_type, source);
g_object_unref (source);
g_warning ("Unable to load the calendar %s \n", e_cal_get_error_message (status));
@@ -2771,7 +2776,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar
g_object_unref (priv->default_client[source_type]);
priv->default_client[source_type] = NULL;
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
+ g_signal_emit (gcal, gnome_calendar_signals[SOURCE_REMOVED], 0, source_type, source);
g_object_unref (source);
g_warning ("Unable to load the calendar %s \n", e_cal_get_error_message (status));
@@ -2893,7 +2898,7 @@ backend_died_cb (ECal *ecal, gpointer data)
e_calendar_view_set_status_message (E_CALENDAR_VIEW (priv->week_view), NULL, -1);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
+ g_signal_emit (gcal, gnome_calendar_signals[SOURCE_REMOVED], 0, source_type, source);
break;
case E_CAL_SOURCE_TYPE_TODO:
@@ -2901,7 +2906,7 @@ backend_died_cb (ECal *ecal, gpointer data)
e_calendar_table_set_status_message (E_CALENDAR_TABLE (priv->todo), NULL, -1);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
+ g_signal_emit (gcal, gnome_calendar_signals[SOURCE_REMOVED], 0, source_type, source);
break;
case E_CAL_SOURCE_TYPE_JOURNAL:
@@ -2909,7 +2914,7 @@ backend_died_cb (ECal *ecal, gpointer data)
e_memo_table_set_status_message (E_MEMO_TABLE (priv->memo), NULL);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
+ g_signal_emit (gcal, gnome_calendar_signals[SOURCE_REMOVED], 0, source_type, source);
break;
default:
g_return_if_reached ();
@@ -3068,7 +3073,7 @@ gnome_calendar_add_source (GnomeCalendar *gcal, ECalSourceType source_type, ESou
g_hash_table_insert (priv->clients[source_type], g_strdup (e_source_peek_uid (source)), client);
priv->clients_list[source_type] = g_list_prepend (priv->clients_list[source_type], client);
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_ADDED], source_type, source);
+ g_signal_emit (gcal, gnome_calendar_signals[SOURCE_ADDED], 0, source_type, source);
open_ecal (gcal, client, FALSE, client_cal_opened_cb);
@@ -3096,7 +3101,7 @@ gnome_calendar_remove_source (GnomeCalendar *gcal, ECalSourceType source_type, E
result = gnome_calendar_remove_source_by_uid (gcal, source_type, e_source_peek_uid (source));
if (result)
- gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
+ g_signal_emit (gcal, gnome_calendar_signals[SOURCE_REMOVED], 0, source_type, source);
return result;
}
@@ -3653,8 +3658,7 @@ gnome_calendar_notify_dates_shown_changed (GnomeCalendar *gcal)
priv->visible_start = start_time;
priv->visible_end = end_time;
- gtk_signal_emit (GTK_OBJECT (gcal),
- gnome_calendar_signals[DATES_SHOWN_CHANGED]);
+ g_signal_emit (gcal, gnome_calendar_signals[DATES_SHOWN_CHANGED], 0);
}
update_memo_view (gcal);
}
diff --git a/calendar/gui/gnome-cal.h b/calendar/gui/gnome-cal.h
index f370c5930a..cc3250f912 100644
--- a/calendar/gui/gnome-cal.h
+++ b/calendar/gui/gnome-cal.h
@@ -40,11 +40,11 @@ G_BEGIN_DECLS
struct _EPopup;
#define GNOME_TYPE_CALENDAR (gnome_calendar_get_type ())
-#define GNOME_CALENDAR(obj) (GTK_CHECK_CAST ((obj), GNOME_TYPE_CALENDAR, GnomeCalendar))
-#define GNOME_CALENDAR_CLASS(klass) (GTK_CHECK_CAST_CLASS ((klass), GNOME_TYPE_CALENDAR, \
+#define GNOME_CALENDAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GNOME_TYPE_CALENDAR, GnomeCalendar))
+#define GNOME_CALENDAR_CLASS(klass) (G_TYPE_CHECK_INSTANCE_CAST_CLASS ((klass), GNOME_TYPE_CALENDAR, \
GnomeCalendarClass))
-#define GNOME_IS_CALENDAR(obj) (GTK_CHECK_TYPE ((obj), GNOME_TYPE_CALENDAR))
-#define GNOME_IS_CALENDAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GNOME_TYPE_CALENDAR))
+#define GNOME_IS_CALENDAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GNOME_TYPE_CALENDAR))
+#define GNOME_IS_CALENDAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GNOME_TYPE_CALENDAR))
typedef struct _GnomeCalendar GnomeCalendar;
typedef struct _GnomeCalendarClass GnomeCalendarClass;
@@ -102,7 +102,7 @@ struct _GnomeCalendarClass {
};
-GtkType gnome_calendar_get_type (void);
+GType gnome_calendar_get_type (void);
GtkWidget *gnome_calendar_construct (GnomeCalendar *gcal);
GtkWidget *gnome_calendar_new (void);
diff --git a/calendar/gui/weekday-picker.c b/calendar/gui/weekday-picker.c
index 709255f374..c74d1a7980 100644
--- a/calendar/gui/weekday-picker.c
+++ b/calendar/gui/weekday-picker.c
@@ -92,12 +92,13 @@ weekday_picker_class_init (WeekdayPickerClass *class)
widget_class = (GtkWidgetClass *) class;
wp_signals[CHANGED] =
- gtk_signal_new ("changed",
- GTK_RUN_FIRST,
+ g_signal_new ("changed",
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (WeekdayPickerClass, changed),
- gtk_marshal_NONE__NONE,
- GTK_TYPE_NONE, 0);
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (WeekdayPickerClass, changed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
object_class->destroy = weekday_picker_destroy;
@@ -504,7 +505,7 @@ weekday_picker_set_days (WeekdayPicker *wp, guint8 day_mask)
priv->day_mask = day_mask;
colorize_items (wp);
- gtk_signal_emit (GTK_OBJECT (wp), wp_signals[CHANGED]);
+ g_signal_emit (GTK_OBJECT (wp), wp_signals[CHANGED], 0);
}
/**
diff --git a/calendar/gui/weekday-picker.h b/calendar/gui/weekday-picker.h
index 9f703b53a6..93777f1e46 100644
--- a/calendar/gui/weekday-picker.h
+++ b/calendar/gui/weekday-picker.h
@@ -28,11 +28,11 @@ G_BEGIN_DECLS
#define TYPE_WEEKDAY_PICKER (weekday_picker_get_type ())
-#define WEEKDAY_PICKER(obj) (GTK_CHECK_CAST ((obj), TYPE_WEEKDAY_PICKER, WeekdayPicker))
-#define WEEKDAY_PICKER_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), TYPE_WEEKDAY_PICKER, \
+#define WEEKDAY_PICKER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_WEEKDAY_PICKER, WeekdayPicker))
+#define WEEKDAY_PICKER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_WEEKDAY_PICKER, \
WeekdayPickerClass))
-#define IS_WEEKDAY_PICKER(obj) (GTK_CHECK_TYPE ((obj), TYPE_WEEKDAY_PICKER))
-#define IS_WEEKDAY_PICKER_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), TYPE_WEEKDAY_PICKER))
+#define IS_WEEKDAY_PICKER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_WEEKDAY_PICKER))
+#define IS_WEEKDAY_PICKER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_WEEKDAY_PICKER))
typedef struct _WeekdayPicker WeekdayPicker;
typedef struct _WeekdayPickerClass WeekdayPickerClass;
@@ -51,7 +51,7 @@ struct _WeekdayPickerClass {
void (* changed) (WeekdayPicker *wp);
};
-GtkType weekday_picker_get_type (void);
+GType weekday_picker_get_type (void);
GtkWidget *weekday_picker_new (void);