aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-meeting-time-sel-item.c
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/gui/e-meeting-time-sel-item.c
parente1d0bcf694c806af75cb4d9683d1941d9721a1f9 (diff)
downloadgsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.tar
gsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.tar.gz
gsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.tar.bz2
gsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.tar.lz
gsoc2013-evolution-e99e12428d46db3be2878f6c2ca63bd7510149f4.tar.xz
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/gui/e-meeting-time-sel-item.c')
-rw-r--r--calendar/gui/e-meeting-time-sel-item.c75
1 files changed, 42 insertions, 33 deletions
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);
}