[evolution-patches] patch to fix the meeting page not getting displayed [calendar]



Hi,
  The meeting page is not shown when the calendar becomes busy in some
cases. Attached the patch to fix it.

thanks, chenthill.
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/calendar/ChangeLog,v
retrieving revision 1.2714
diff -u -p -r1.2714 ChangeLog
--- ChangeLog	18 Apr 2005 14:32:16 -0000	1.2714
+++ ChangeLog	21 Apr 2005 06:54:09 -0000
@@ -1,3 +1,11 @@
+2005-04-21  Chenthill Palanisamy  <pchenthill novell com>
+
+	* gui/dialogs/meeting-page.c
+       	(meeting_page_construct): Added a check
+	for the BUSY status in e_cal_get_cal_address, to ensure we display the 
+	meetings tab. Added two assertion statements to ensure the validity of the 
+	ecal and to ensure it has been loaded.
+
 2005-04-18  Chenthill Palanisamy  <pchenthill novell com>
 
 	Fixes #274476
Index: gui/dialogs/meeting-page.c
===================================================================
RCS file: /cvs/gnome/evolution/calendar/gui/dialogs/meeting-page.c,v
retrieving revision 1.96
diff -u -p -r1.96 meeting-page.c
--- gui/dialogs/meeting-page.c	24 Mar 2005 08:34:12 -0000	1.96
+++ gui/dialogs/meeting-page.c	21 Apr 2005 06:54:09 -0000
@@ -854,7 +854,11 @@ meeting_page_construct (MeetingPage *mpa
 	EIterator *it;
 	EAccount *def_account;
 	GList *address_strings = NULL, *l;
+	GError *error = NULL;
 	GtkWidget *sw;
+
+	g_return_val_if_fail (client && E_IS_CAL (client), NULL);	
+	g_return_val_if_fail (e_cal_get_load_state (client) == E_CAL_LOAD_LOADED, NULL);
 	
 	priv = mpage->priv;
 
@@ -871,8 +875,12 @@ meeting_page_construct (MeetingPage *mpa
 	}
 
 	/* Address information */
-	if (!e_cal_get_cal_address (client, &backend_address, NULL))
-		return NULL;
+	if (!e_cal_get_cal_address (client, &backend_address, &error)) {
+		if (error->code == E_CALENDAR_STATUS_BUSY)
+			g_message (G_STRLOC ": Could not get the cal address, calendar is busy");
+
+		g_error_free (error);
+	}
 
 	priv->accounts = itip_addresses_get ();
 	def_account = itip_addresses_get_default();


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