From 81c0869a03e3429685eed1a5598e7d0ea6975bcf Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Mon, 4 Jan 2010 23:14:04 -0600 Subject: Making a label --- src/indicator-datetime.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/indicator-datetime.c b/src/indicator-datetime.c index c022a99..16a792c 100644 --- a/src/indicator-datetime.c +++ b/src/indicator-datetime.c @@ -32,7 +32,7 @@ struct _IndicatorDatetime { }; struct _IndicatorDatetimePrivate { - int dummy; + GtkLabel * label; }; #define INDICATOR_DATETIME_GET_PRIVATE(o) \ @@ -96,7 +96,12 @@ indicator_datetime_finalize (GObject *object) static GtkLabel * get_label (IndicatorObject * io) { + IndicatorDatetime * self = INDICATOR_DATETIME(io); + if (self->priv->label == NULL) { + self->priv->label = GTK_LABEL(gtk_label_new("Time")); + gtk_widget_show(GTK_WIDGET(self->priv->label)); + } - return NULL; + return self->priv->label; } -- cgit v1.2.3