[evolution-exchange] Adapt to CamelFolderInfo changes.



commit 41be20d2093fe7728d094386f220684e7f3c6bc2
Author: Matthew Barnes <mbarnes redhat com>
Date:   Mon May 2 22:08:44 2011 -0400

    Adapt to CamelFolderInfo changes.

 camel/camel-exchange-store.c |   17 +++--------------
 eplugin/exchange-folder.c    |   10 ++++++----
 2 files changed, 9 insertions(+), 18 deletions(-)
---
diff --git a/camel/camel-exchange-store.c b/camel/camel-exchange-store.c
index c62bfdb..95dd027 100644
--- a/camel/camel-exchange-store.c
+++ b/camel/camel-exchange-store.c
@@ -52,18 +52,16 @@ extern CamelServiceAuthType camel_exchange_ntlm_authtype;
 
 G_DEFINE_TYPE (CamelExchangeStore, camel_exchange_store, CAMEL_TYPE_OFFLINE_STORE)
 
-/* Note: steals @name and @uri */
+/* Note: steals @display_name. */
 static CamelFolderInfo *
 make_folder_info (CamelExchangeStore *exch,
-                  gchar *name,
+                  gchar *display_name,
                   const gchar *uri,
                   gint unread_count,
                   gint flags)
 {
 	CamelFolderInfo *info;
 	const gchar *path;
-	gchar **components;
-	gchar *new_uri;
 	gchar *temp;
 
 	d(printf ("make folder info : %s flags : %d\n", name, flags));
@@ -74,17 +72,8 @@ make_folder_info (CamelExchangeStore *exch,
 	if (!path)
 		return NULL;
 
-	components = g_strsplit (uri, "/;", 2);
-	if (components[0] && components[1])
-		new_uri = g_strdup_printf ("%s/%s", components[0], components[1]);
-	else
-		new_uri = g_strdup (uri);
-	g_strfreev (components);
-
-	d(printf ("new_uri is : %s\n", new_uri));
 	info = camel_folder_info_new ();
-	info->name = name;
-	info->uri = new_uri;
+	info->display_name = display_name;
 
 	/* Process the full-path and decode if required */
 	temp = strrchr (path+2, '/');
diff --git a/eplugin/exchange-folder.c b/eplugin/exchange-folder.c
index 5d6a15b..1555d81 100644
--- a/eplugin/exchange-folder.c
+++ b/eplugin/exchange-folder.c
@@ -42,8 +42,11 @@
 #define CONF_KEY_SELECTED_CAL_SOURCES "/apps/evolution/calendar/display/selected_calendars"
 
 static CamelFolderInfo *
-ex_create_folder_info (CamelStore *store, gchar *name, gchar *uri,
-                  gint unread_count, gint flags)
+ex_create_folder_info (CamelStore *store,
+                       gchar *display_name,
+                       gchar *uri,
+                       gint unread_count,
+                       gint flags)
 {
 	CamelFolderInfo *info;
 	const gchar *path;
@@ -56,9 +59,8 @@ ex_create_folder_info (CamelStore *store, gchar *name, gchar *uri,
 		return NULL;
 
 	info = camel_folder_info_new ();
-	info->name = name;
-	info->uri = uri;
 	info->full_name = g_strdup (path + 1);
+	info->display_name = display_name;
 	info->unread = unread_count;
 
 	return info;



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