Monotone-Parent: 52e582748151e87bfde51bfd7c475d994270767b

Monotone-Revision: cc4465af2bc376a873ae8e59faf33b86548f08b3

Monotone-Author: crobert@inverse.ca
Monotone-Date: 2009-07-01T19:28:44
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
C Robert
2009-07-01 19:28:44 +00:00
parent a40feed75c
commit 733cc4f9e7
2 changed files with 23 additions and 1 deletions
+2
View File
@@ -2,6 +2,8 @@
* SoObjects/SOGo/SOGoGCSFolder.m: Remove color from user settings on
unsubscribe.
* UI/MailerUI/UIxMailFolderActions.m (_trashedURLOfFolder:withCO:): Fixed
issue when deleting a folder with the same name as one already in the Trash.
2009-06-30 Wolfgang Sourdeau <wsourdeau@inverse.ca>
+21 -1
View File
@@ -139,13 +139,33 @@
withCO: (SOGoMailFolder *) co
{
NSURL *destURL;
NSString *trashFolderName, *folderName, *path;
NSString *trashFolderName, *folderName, *path, *testPath;
NGImap4Connection *connection;
int i = 1;
id test;
connection = [co imap4Connection];
folderName = [[srcURL path] lastPathComponent];
trashFolderName
= [[co mailAccountFolder] trashFolderNameInContext: context];
path = [NSString stringWithFormat: @"/%@/%@",
trashFolderName, folderName];
testPath = path;
while ( i < 10 )
{
test = [[connection client] select: testPath];
if (test && [[test objectForKey: @"result"] boolValue])
{
testPath = [NSString stringWithFormat: @"%@%x", path, i];
i++;
}
else
{
path = testPath;
break;
}
}
destURL = [[NSURL alloc] initWithScheme: [srcURL scheme]
host: [srcURL host] path: path];
[destURL autorelease];