[evolution-patches] [Tasks] Fix for Bug #323984



Hi, 

The attached patch fixes Bug #323984 where a new task still shows the
timezone widgets when gconf tells it not. Thus evolution respects to the
value of /apps/evolution/calendar/display/show_timezone and responds
correctly to its change in gconf. So, it helps to implement central
management over evolution.  

Please take some time to review it. 

Thanks,
Sam Yang
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/calendar/ChangeLog,v
retrieving revision 1.2894
diff -u -r1.2894 ChangeLog
--- ChangeLog	19 Dec 2005 11:23:09 -0000	1.2894
+++ ChangeLog	20 Dec 2005 02:51:33 -0000
@@ -1,3 +1,12 @@
+2005-12-20  Sam Yang  <sam yang sun com>
+
+	Fixes #323984
+	* gui/dialogs/task-page.c: (task_page_fill_widgets): Invoke task_page_set_show_timezone() to check 
+	whether to show timezone widgets on task page. Just like what we did in init_widgets(). 
+	(init_widgets): Since we have called task_page_set_show_timezone() before, remove its duplicate code. Invoke
+	task_page_set_show_categories() directly other than copy its code here.
+    	    
+
 2005-12-19  Chenthill Palanisamy  <pchenthill novell com>
 	
 	Committing for David Trowbridge <trowbrds cs colorado edu>
Index: gui/dialogs/task-page.c
===================================================================
RCS file: /cvs/gnome/evolution/calendar/gui/dialogs/task-page.c,v
retrieving revision 1.77
diff -u -r1.77 task-page.c
--- gui/dialogs/task-page.c	26 Nov 2005 02:31:52 -0000	1.77
+++ gui/dialogs/task-page.c	20 Dec 2005 02:51:33 -0000
@@ -595,7 +595,7 @@
 	
 	e_timezone_entry_set_timezone (E_TIMEZONE_ENTRY (priv->timezone),
 				       zone ? zone : default_zone);
-	gtk_widget_show_all (priv->timezone);
+	task_page_set_show_timezone (tpage, calendar_config_get_show_timezone());
 
 	if (!(COMP_EDITOR_PAGE (tpage)->flags & COMP_EDITOR_PAGE_NEW_ITEM) && !zone) {
 			task_page_set_show_timezone (tpage, FALSE);
@@ -1746,21 +1746,7 @@
 	e_meeting_list_view_column_set_visible (priv->list_view, "Status", calendar_config_get_show_status());
 	e_meeting_list_view_column_set_visible (priv->list_view, "Type", calendar_config_get_show_type());
 	
-	if (!calendar_config_get_show_timezone()) {
-		gtk_widget_hide (priv->timezone_label);
-		gtk_widget_hide (priv->timezone);
-	} else {
-		gtk_widget_show (priv->timezone_label);
-		gtk_widget_show_all (priv->timezone);
-	}
-
-	if (!calendar_config_get_show_categories()) {
-		gtk_widget_hide (priv->categories_btn);
-		gtk_widget_hide (priv->categories);
-	} else {
-		gtk_widget_show (priv->categories_btn);
-		gtk_widget_show (priv->categories);
-	}	
+	task_page_set_show_categories (tpage, calendar_config_get_show_categories());
 
 	return TRUE;
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]