From b6313289303f2263649c70ea477e04aea4a994ec Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Tue, 4 Aug 2009 15:04:02 +0200 Subject: Bug #205137 - Configurable date formats in components --- calendar/gui/dialogs/cal-prefs-dialog.c | 8 ++- calendar/gui/dialogs/cal-prefs-dialog.glade | 79 +++++++++++++++++++++++++++++ 2 files changed, 86 insertions(+), 1 deletion(-) (limited to 'calendar/gui/dialogs') diff --git a/calendar/gui/dialogs/cal-prefs-dialog.c b/calendar/gui/dialogs/cal-prefs-dialog.c index 2c19acaadd..2fc17202cc 100644 --- a/calendar/gui/dialogs/cal-prefs-dialog.c +++ b/calendar/gui/dialogs/cal-prefs-dialog.c @@ -31,6 +31,7 @@ #include "../calendar-config.h" #include "cal-prefs-dialog.h" #include +#include "e-util/e-datetime-format.h" #include #include #include @@ -779,7 +780,7 @@ calendar_prefs_dialog_construct (CalendarPrefsDialog *prefs) ECalConfig *ec; ECalConfigTargetPrefs *target; gint i; - GtkWidget *toplevel; + GtkWidget *toplevel, *table; GSList *l; const gchar *working_day_names[] = { "sun_button", @@ -859,6 +860,11 @@ calendar_prefs_dialog_construct (CalendarPrefsDialog *prefs) toplevel = e_config_create_widget ((EConfig *)ec); gtk_container_add (GTK_CONTAINER (prefs), toplevel); + /* date/time format */ + table = glade_xml_get_widget (gui, "datetime_format_table"); + e_datetime_format_add_setup_widget (table, 0, "calendar", "table", DTFormatKindDateTime, _("Time and date:")); + e_datetime_format_add_setup_widget (table, 1, "calendar", "table", DTFormatKindDate, _("Date only:")); + show_config (prefs); /* FIXME: weakref? */ setup_changes (prefs); diff --git a/calendar/gui/dialogs/cal-prefs-dialog.glade b/calendar/gui/dialogs/cal-prefs-dialog.glade index 63e9e6092f..984e509b64 100644 --- a/calendar/gui/dialogs/cal-prefs-dialog.glade +++ b/calendar/gui/dialogs/cal-prefs-dialog.glade @@ -1024,6 +1024,85 @@ Days 3 + + + + True + <span weight="bold">Date/Time Format</span> + False + True + GTK_JUSTIFY_LEFT + False + False + 0 + 0.5 + 0 + 0 + PANGO_ELLIPSIZE_NONE + -1 + False + 0 + + + 0 + False + False + + + + + + True + False + 12 + + + + True + + False + False + GTK_JUSTIFY_LEFT + False + False + 0.5 + 0.5 + 0 + 0 + PANGO_ELLIPSIZE_NONE + -1 + False + 0 + + + 0 + False + False + + + + + + True + 1 + 3 + False + 0 + 0 + + + 0 + True + True + + + + + 0 + True + True + + 1 -- cgit v1.2.3