[evolution-patches] Patch for #59376



Hi,

Attached is the fix for 59376.
Please review this.

Thanks,
Sushma.
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/addressbook/ChangeLog,v
retrieving revision 1.1758
diff -u -r1.1758 ChangeLog
--- ChangeLog	17 Jun 2004 05:01:08 -0000	1.1758
+++ ChangeLog	17 Jun 2004 08:23:15 -0000
@@ -1,3 +1,8 @@
+2004-06-17  Sushma Rai  <rsushma novell com>
+
+	* gui/component/addressbook-view.c (fill_popup_menu_callback):
+	Handling the case where absolute URI is used instead of relative URI.
+
 2004-06-17  Sivaiah Nallagatla <snallagatla novell com>
 
         * gui/widgets/e-addressbook-view.etspec : update
Index: gui/component/addressbook-view.c
===================================================================
RCS file: /cvs/gnome/evolution/addressbook/gui/component/addressbook-view.c,v
retrieving revision 1.10
diff -u -r1.10 addressbook-view.c
--- gui/component/addressbook-view.c	7 Jun 2004 15:36:39 -0000	1.10
+++ gui/component/addressbook-view.c	17 Jun 2004 08:23:44 -0000
@@ -743,14 +743,19 @@
 {
 	AddressbookViewPrivate *priv = view->priv;
 	gboolean sensitive;
-	gboolean local_addressbook;
+	gboolean local_addressbook = FALSE;
 	ESource *selected_source;
+	const char *uri = NULL;
 
 	selected_source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (priv->selector));
 	sensitive = selected_source ? TRUE : FALSE;
 
-	local_addressbook =  (!strcmp ("system", e_source_peek_relative_uri (selected_source)));
-		
+	uri = e_source_peek_relative_uri (selected_source);
+	if (!uri) 
+		uri = e_source_peek_absolute_uri (selected_source);
+
+	local_addressbook =  (!strcmp ("system", uri));	
+
 	add_popup_menu_item (menu, _("New Address Book"), NULL, G_CALLBACK (new_addressbook_cb), view, TRUE);
 	add_popup_menu_item (menu, _("Delete"), GTK_STOCK_DELETE, G_CALLBACK (delete_addressbook_cb), view, sensitive && !local_addressbook);
 	add_popup_menu_item (menu, _("Properties..."), NULL, G_CALLBACK (edit_addressbook_cb), view, sensitive);


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