[evolution-patches] Exchange: Fix for 'Unsubscribe to Inbox' and 'folder permission'
- From: shakti <shprasad novell com>
- To: evolution-patches gnome org
- Subject: [evolution-patches] Exchange: Fix for 'Unsubscribe to Inbox' and 'folder permission'
- Date: Mon, 03 Oct 2005 18:27:29 +0530
Hi,
I have attached a patch which fixes the followings;
- Unsubscribe to other User's Inbox'
- Permissions for Inbox
Somehow the above two were broken. This patch fixes it. Please have a
look at it.
Thanks,
Shakti
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/plugins/exchange-operations/ChangeLog,v
retrieving revision 1.58
diff -u -p -r1.58 ChangeLog
--- ChangeLog 30 Sep 2005 06:37:42 -0000 1.58
+++ ChangeLog 3 Oct 2005 11:12:36 -0000
@@ -1,3 +1,17 @@
+2005-10-03 Shakti Sen <shprasad novell com>
+
+ * exchange-folder-permission.c (org_gnome_exchange_folder_permissions),
+ (org_gnome_exchange_menu_folder_permission): Constructing the path
+ properly to get the efolder.
+ * exchange-folder.c (org_gnome_exchange_folder_inbox_unsubscribe),
+ (exchange_get_folder), (org_gnome_exchange_check_inbox_subscribed),
+ (unsubscribe_dialog_ab_response), (unsubscribe_dialog_response):
+ Creating proper path.
+
+ The above modifications will allow the user to do the operations like
+ unsubscribed to Inbox and giving permission to a folder.
+ -
+
2005-09-30 Shakti Sen <shprasad novell com>
* exchange-folder-subscription.c (setup_folder_name_combo): Sets the
Index: exchange-folder-permission.c
===================================================================
RCS file: /cvs/gnome/evolution/plugins/exchange-operations/exchange-folder-permission.c,v
retrieving revision 1.7
diff -u -p -r1.7 exchange-folder-permission.c
--- exchange-folder-permission.c 2 Aug 2005 14:37:59 -0000 1.7
+++ exchange-folder-permission.c 3 Oct 2005 11:12:36 -0000
@@ -149,13 +149,18 @@ org_gnome_exchange_folder_permissions (E
GSList *menus = NULL;
int i = 0;
static int first =0;
+ gchar *path = NULL;
ExchangeAccount *account = exchange_operations_get_exchange_account ();
- if (!account || ! g_strrstr (target->uri, "exchange://") ||
- !exchange_account_get_folder (account, target->uri))
+ if (!account)
+ return;
+
+ path = target->uri + strlen ("exchange://") + strlen (account->account_filename);
+ if (! g_strrstr (target->uri, "exchange://") ||
+ !exchange_account_get_folder (account, path))
return ;
- selected_exchange_folder_uri = target->uri;
+ selected_exchange_folder_uri = path;
/* for translation*/
if (!first) {
popup_items[0].label = _(popup_items[0].label);
@@ -191,13 +196,15 @@ org_gnome_exchange_menu_folder_permissio
{
ExchangeAccount *account = NULL;
EFolder *folder = NULL;
+ gchar *path = NULL;
account = exchange_operations_get_exchange_account ();
if (!account)
return;
- folder = exchange_account_get_folder (account, target->uri);
+ path = target->uri + strlen ("exchange://") + strlen (account->account_filename);
+ folder = exchange_account_get_folder (account, path);
if (folder)
exchange_permissions_dialog_new (account, folder, NULL);
}
Index: exchange-folder.c
===================================================================
RCS file: /cvs/gnome/evolution/plugins/exchange-operations/exchange-folder.c,v
retrieving revision 1.14
diff -u -p -r1.14 exchange-folder.c
--- exchange-folder.c 30 Sep 2005 06:37:42 -0000 1.14
+++ exchange-folder.c 3 Oct 2005 11:12:36 -0000
@@ -91,7 +91,7 @@ org_gnome_exchange_folder_inbox_unsubscr
return;
target_uri = g_strdup (target->uri);
- path = target->uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;");
+ path = target->uri + strlen ("exchange://") + strlen (account->account_filename);
/* User will be able to unsubscribe by doing a right click on
any one of this two-<other user's>Inbox or the
<other user's folder> tree.
@@ -179,7 +179,7 @@ exchange_get_folder (char *uri, CamelFol
return;
/* Get the subscribed folder name. */
- name = target_uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;");
+ name = target_uri + strlen ("exchange://") + strlen (account->account_filename);
stored_name = strrchr (name + 1, '/');
if (stored_name)
@@ -209,7 +209,7 @@ org_gnome_exchange_check_inbox_subscribe
if (!account)
return;
- path = g_strdup (target->uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;"));
+ path = g_strdup (target->uri + strlen ("exchange://") + strlen (account->account_filename));
sub_folder = strchr (path, '@');
g_free (path);
@@ -347,7 +347,7 @@ unsubscribe_dialog_ab_response (GtkDialo
source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (target->selector));
uri = e_source_get_uri (source);
- path = g_strdup (uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;"));
+ path = g_strdup (uri + strlen ("exchange://") + strlen (account->account_filename));
source_uid = e_source_peek_uid (source);
exchange_account_remove_shared_folder (account, path);
@@ -389,7 +389,7 @@ unsubscribe_dialog_response (GtkDialog *
ruri = (gchar *) e_source_peek_relative_uri (source);
source_uid = e_source_peek_uid (source);
- path = g_strdup (ruri + strlen (account->account_filename) + strlen ("/;"));
+ path = g_strdup (ruri + strlen (account->account_filename));
exchange_account_remove_shared_folder (account, path);
ids = gconf_client_get_list (client,
CONF_KEY_SELECTED_CAL_SOURCES,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]