From 054c0881696a85f537e93b4950a28f505a3dc0f7 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Thu, 24 Sep 2009 18:04:36 -0400 Subject: =?UTF-8?q?Bug=C2=A0589153=20-=20Use=20GtkBuilder=20instead=20of?= =?UTF-8?q?=20libglade?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- calendar/gui/dialogs/comp-editor-util.c | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) (limited to 'calendar/gui/dialogs/comp-editor-util.c') diff --git a/calendar/gui/dialogs/comp-editor-util.c b/calendar/gui/dialogs/comp-editor-util.c index 07b776912d..271ac5a8cc 100644 --- a/calendar/gui/dialogs/comp-editor-util.c +++ b/calendar/gui/dialogs/comp-editor-util.c @@ -36,6 +36,7 @@ #include "widgets/misc/e-dateedit.h" #include "../calendar-config.h" #include "../itip-utils.h" +#include #include "comp-editor-util.h" @@ -239,15 +240,27 @@ comp_editor_new_date_edit (EShellSettings *shell_settings, e_date_edit_set_make_time_insensitive (dedit, FALSE); #endif + comp_editor_bind_date_edit_settings (GTK_WIDGET (dedit), shell_settings); + + return GTK_WIDGET (dedit); +} + +void +comp_editor_bind_date_edit_settings (GtkWidget *dateedit, EShellSettings *shell_settings) +{ + g_return_if_fail (dateedit != NULL); + g_return_if_fail (E_IS_DATE_EDIT (dateedit)); + + if (!shell_settings) + shell_settings = e_shell_get_shell_settings (e_shell_get_default ()); + e_binding_new ( shell_settings, "cal-show-week-numbers", - dedit, "show-week-numbers"); + dateedit, "show-week-numbers"); e_binding_new ( shell_settings, "cal-week-start-day", - dedit, "week-start-day"); - - return GTK_WIDGET (dedit); + dateedit, "week-start-day"); } /* Returns the current time, for EDateEdit widgets and ECalendar items in the -- cgit v1.2.3