From e4316274c946d49917e72ee7f60b297578dccf80 Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Tue, 15 Mar 2011 19:36:25 +0000 Subject: [PATCH] See Changelog Monotone-Parent: 0a48d70dd58905fd233548415a50a48cf1114607 Monotone-Revision: f16945cd420c09a7d8ad18f9ffc3d9f902c7a2bf Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2011-03-15T19:36:25 Monotone-Branch: ca.inverse.sogo --- ChangeLog | 8 ++++++++ UI/MailerUI/UIxMailListActions.m | 29 +++++------------------------ UI/MailerUI/product.plist | 26 -------------------------- 3 files changed, 13 insertions(+), 50 deletions(-) diff --git a/ChangeLog b/ChangeLog index 9e006f422..73fb3d9fd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2011-03-15 francis + + * UI/MailerUI/UIxMailListActions.m (-getMailAction): removed this + method that is no longer used since live-loading. + (-getSortedUIDsAction): restored the call to + expungeLastMarkedFolder so that the last visited folder is + expunged when switching folder. + 2011-03-11 Wolfgang Sourdeau * SoObjects/Contacts/SOGoContactFolders.m diff --git a/UI/MailerUI/UIxMailListActions.m b/UI/MailerUI/UIxMailListActions.m index e43e3e065..459f0bf74 100644 --- a/UI/MailerUI/UIxMailListActions.m +++ b/UI/MailerUI/UIxMailListActions.m @@ -1,6 +1,6 @@ /* Copyright (C) 2004-2005 SKYRIX Software AG - Copyright (C) 2006-2010 Inverse inc. + Copyright (C) 2006-2011 Inverse inc. This file is part of SOGo @@ -512,28 +512,6 @@ /* actions */ -- (id) getMailAction -{ - // TODO: we might want to flush the caches? - id client; - - if ((client = [self clientObject]) == nil) { - return [NSException exceptionWithHTTPStatus:404 /* Not Found */ - reason:@"did not find mail folder"]; - } - - if (![client respondsToSelector:@selector(flushMailCaches) ]) - { - return [NSException exceptionWithHTTPStatus: 500 /* Server Error */ - reason: - @"invalid client object (does not support flush)"]; - } - - [client flushMailCaches]; - - return [self redirectToLocation:@"view"]; -} - - (NSDictionary *) getUIDsAndHeadersInFolder: (SOGoMailFolder *) mailFolder { NSArray *uids, *headers; @@ -569,6 +547,9 @@ [response setHeader: @"text/plain; charset=utf-8" forKey: @"content-type"]; folder = [self clientObject]; + // TODO: we might want to flush the caches? + //[folder flushMailCaches]; + [folder expungeLastMarkedFolder]; noHeaders = [request formValueForKey: @"no_headers"]; if ([noHeaders length]) data = [self getSortedUIDsInFolder: folder]; @@ -576,7 +557,7 @@ data = [self getUIDsAndHeadersInFolder: folder]; [response appendContentString: [data jsonRepresentation]]; - + return response; } diff --git a/UI/MailerUI/product.plist b/UI/MailerUI/product.plist index 45fa5e6f9..89ba0d7a7 100644 --- a/UI/MailerUI/product.plist +++ b/UI/MailerUI/product.plist @@ -77,11 +77,6 @@ }; }; methods = { - getMail = { - protectedBy = "View"; - actionClass = "UIxMailListActions"; - actionName = "getMail"; - }; uids = { protectedBy = ""; actionClass = "UIxMailListActions"; @@ -410,27 +405,6 @@ }; }; - SOGoDraftsFolder = { - slots = { - toolbar = { - protectedBy = "View"; - value = ( /* the toolbar groups */ - ( /* first group */ - { link = "getMail"; - image = "tb-mail-getmail-flat-24x24.png"; - cssClass = "tbicon_getmail"; label = "Get Mail"; }, - { - link = "#"; // "compose"; // target = "_blank"; - isSafe = NO; - onclick = "return openMessageWindow(null, 'compose');"; - image = "tb-mail-write-flat-24x24.png"; - cssClass = "tbicon_compose"; label = "Write"; }, - ) - ); - }; - }; - }; - SOGoDraftObject = { slots = { toolbar = {