diff options
author | JP Rosevear <jpr@novell.com> | 2004-11-26 23:15:36 +0800 |
---|---|---|
committer | JP Rosevear <jpr@src.gnome.org> | 2004-11-26 23:15:36 +0800 |
commit | ba0bc7dff09ade6b8014183c44c4c44b42ed1396 (patch) | |
tree | 0394c1dde4cb58e40b4694e0a486f5e37f147750 /widgets/misc/e-calendar.c | |
parent | f484ce17b3651e8d741e789621f59baef1652974 (diff) | |
download | gsoc2013-evolution-ba0bc7dff09ade6b8014183c44c4c44b42ed1396.tar.gz gsoc2013-evolution-ba0bc7dff09ade6b8014183c44c4c44b42ed1396.tar.zst gsoc2013-evolution-ba0bc7dff09ade6b8014183c44c4c44b42ed1396.zip |
test prog
2004-11-26 JP Rosevear <jpr@novell.com>
* test-info-label.c: test prog
* e-url-entry.c: get image directly from icon factory
* e-combo-button.c: ditto; convert to G_DEFINE_TYPE
* e-activity-handler.c: convert to G_DEFINE_TYPE
* e-task-widget.c: ditto
* e-task-bar.c: ditto
* e-multi-config-dialog.c: ditto
* e-dropdown-button.c: ditto
* e-cell-renderer-combo.c: ditto
* e-cell-date-edit.c: ditto
* e-calendar.c: ditto
* e-calendar-item.c: ditto
* Makefile.am: don't build the title bar, build an info label test
program
svn path=/trunk/; revision=27999
Diffstat (limited to 'widgets/misc/e-calendar.c')
-rw-r--r-- | widgets/misc/e-calendar.c | 26 |
1 files changed, 9 insertions, 17 deletions
diff --git a/widgets/misc/e-calendar.c b/widgets/misc/e-calendar.c index 5fca4ab074..c8798b5cfa 100644 --- a/widgets/misc/e-calendar.c +++ b/widgets/misc/e-calendar.c @@ -30,7 +30,9 @@ * to got to the current day. */ +#ifdef HAVE_CONFIG_H #include <config.h> +#endif #include "e-calendar.h" @@ -41,7 +43,6 @@ #include <gtk/gtkpixmap.h> #include <gtk/gtksignal.h> #include <libgnomecanvas/gnome-canvas-widget.h> -#include <gal/util/e-util.h> #include <libgnome/gnome-i18n.h> #define E_CALENDAR_SMALL_FONT_PTSIZE 6 @@ -70,8 +71,6 @@ #define E_CALENDAR_AUTO_MOVE_TIMEOUT 150 #define E_CALENDAR_AUTO_MOVE_TIMEOUT_DELAY 2 -static void e_calendar_class_init (ECalendarClass *class); -static void e_calendar_init (ECalendar *cal); static void e_calendar_destroy (GtkObject *object); static void e_calendar_realize (GtkWidget *widget); static void e_calendar_style_set (GtkWidget *widget, @@ -104,11 +103,7 @@ static void e_calendar_start_auto_move (ECalendar *cal, static gboolean e_calendar_auto_move_handler (gpointer data); static void e_calendar_stop_auto_move (ECalendar *cal); -static GnomeCanvasClass *parent_class; -static GtkLayoutClass *grandparent_class; - -E_MAKE_TYPE (e_calendar, "ECalendar", ECalendar, - e_calendar_class_init, e_calendar_init, E_CANVAS_TYPE) +G_DEFINE_TYPE (ECalendar, e_calendar, E_CANVAS_TYPE) static void @@ -120,9 +115,6 @@ e_calendar_class_init (ECalendarClass *class) object_class = (GtkObjectClass *) class; widget_class = (GtkWidgetClass *) class; - parent_class = g_type_class_ref(E_CANVAS_TYPE); - grandparent_class = g_type_class_ref(GTK_TYPE_LAYOUT); - object_class->destroy = e_calendar_destroy; widget_class->realize = e_calendar_realize; @@ -252,15 +244,15 @@ e_calendar_destroy (GtkObject *object) cal->timeout_id = 0; } - if (GTK_OBJECT_CLASS (parent_class)->destroy) - (* GTK_OBJECT_CLASS (parent_class)->destroy) (object); + if (GTK_OBJECT_CLASS (e_calendar_parent_class)->destroy) + (* GTK_OBJECT_CLASS (e_calendar_parent_class)->destroy) (object); } static void e_calendar_realize (GtkWidget *widget) { - (*GTK_WIDGET_CLASS (parent_class)->realize) (widget); + (*GTK_WIDGET_CLASS (e_calendar_parent_class)->realize) (widget); /* Set the background of the canvas window to the normal color, or the arrow buttons are not displayed properly. */ @@ -273,8 +265,8 @@ static void e_calendar_style_set (GtkWidget *widget, GtkStyle *previous_style) { - if (GTK_WIDGET_CLASS (parent_class)->style_set) - (*GTK_WIDGET_CLASS (parent_class)->style_set) (widget, + if (GTK_WIDGET_CLASS (e_calendar_parent_class)->style_set) + (*GTK_WIDGET_CLASS (e_calendar_parent_class)->style_set) (widget, previous_style); /* Set the background of the canvas window to the normal color, @@ -324,7 +316,7 @@ e_calendar_size_allocate (GtkWidget *widget, xthickness = widget->style->xthickness; ythickness = widget->style->ythickness; - (*GTK_WIDGET_CLASS (parent_class)->size_allocate) (widget, allocation); + (*GTK_WIDGET_CLASS (e_calendar_parent_class)->size_allocate) (widget, allocation); /* Set up Pango prerequisites */ font_desc = gtk_widget_get_style (widget)->font_desc; |