diff options
author | Rodney Dawes <dobey@novell.com> | 2004-09-14 04:52:19 +0800 |
---|---|---|
committer | Rodney Dawes <dobey@src.gnome.org> | 2004-09-14 04:52:19 +0800 |
commit | 8c8b6c748e678e496cdac28e4c0a31407ceb1dcb (patch) | |
tree | 64a5cc41d7f6df7b4a7d75acdd228c0c2aed636b /widgets/e-timezone-dialog/e-timezone-dialog.c | |
parent | d4d329fa5f95aec330f65c8b95dbde2125ae51d5 (diff) | |
download | gsoc2013-evolution-8c8b6c748e678e496cdac28e4c0a31407ceb1dcb.tar.gz gsoc2013-evolution-8c8b6c748e678e496cdac28e4c0a31407ceb1dcb.tar.zst gsoc2013-evolution-8c8b6c748e678e496cdac28e4c0a31407ceb1dcb.zip |
Add the label back for previewing the timezone name, and set the label
2004-09-13 Rodney Dawes <dobey@novell.com>
* e-timezone-dialog/e-timezone-dialog.c (get_widgets):
(on_map_motion, on_map_leave, e_timezone_dialog_set_timezone):
* e-timezone-dialog/e-timezone-dialog.glade:
Add the label back for previewing the timezone name, and set the
label appropriately
Fixes #64800
svn path=/trunk/; revision=27258
Diffstat (limited to 'widgets/e-timezone-dialog/e-timezone-dialog.c')
-rw-r--r-- | widgets/e-timezone-dialog/e-timezone-dialog.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/widgets/e-timezone-dialog/e-timezone-dialog.c b/widgets/e-timezone-dialog/e-timezone-dialog.c index 2a179dc465..19a5685b38 100644 --- a/widgets/e-timezone-dialog/e-timezone-dialog.c +++ b/widgets/e-timezone-dialog/e-timezone-dialog.c @@ -59,6 +59,7 @@ struct _ETimezoneDialogPrivate { GtkWidget *table; GtkWidget *map_window; GtkWidget *timezone_combo; + GtkWidget *preview_label; }; @@ -296,11 +297,13 @@ get_widgets (ETimezoneDialog *etd) priv->map_window = GW ("map-window"); priv->timezone_combo = GW ("timezone-combo"); priv->table = GW ("timezone-table"); + priv->preview_label = GW ("preview-label"); return (priv->app && priv->map_window && priv->timezone_combo - && priv->table); + && priv->table + && priv->preview_label); } @@ -321,7 +324,6 @@ e_timezone_dialog_new (void) return e_timezone_dialog_construct (E_TIMEZONE_DIALOG (etd)); } - static const char * zone_display_name (icaltimezone *zone) { @@ -387,7 +389,7 @@ on_map_motion (GtkWidget *widget, GdkEventMotion *event, gpointer data) new_zone = get_zone_from_point (etd, priv->point_hover); - gtk_entry_set_text (GTK_ENTRY (GTK_COMBO (priv->timezone_combo)->entry), + gtk_label_set_text (GTK_LABEL (priv->preview_label), zone_display_name (new_zone)); return TRUE; @@ -415,6 +417,7 @@ on_map_leave (GtkWidget *widget, GdkEventCrossing *event, gpointer data) gtk_entry_set_text (GTK_ENTRY (GTK_COMBO (priv->timezone_combo)->entry), zone_display_name (priv->zone)); + gtk_label_set_text (GTK_LABEL (priv->preview_label), ""); priv->point_hover = NULL; @@ -568,6 +571,8 @@ e_timezone_dialog_set_timezone (ETimezoneDialog *etd, priv->zone = zone; + gtk_label_set_text (GTK_LABEL (priv->preview_label), + zone ? zone_display_name (zone) : ""); gtk_entry_set_text (GTK_ENTRY (GTK_COMBO (priv->timezone_combo)->entry), zone ? zone_display_name (zone) : ""); |