style(obj-c): improve formatting
parent
38b95af9fd
commit
451989ac9c
|
@ -52,8 +52,7 @@
|
||||||
* There's no GUI to defined such conditions, so there's no
|
* There's no GUI to defined such conditions, so there's no
|
||||||
* problem for now.
|
* problem for now.
|
||||||
*/
|
*/
|
||||||
- (NSArray *)
|
- (NSArray *) recurrenceRangesWithinCalendarDateRange: (NGCalendarDateRange *) _r
|
||||||
recurrenceRangesWithinCalendarDateRange: (NGCalendarDateRange *) _r
|
|
||||||
{
|
{
|
||||||
NSMutableArray *ranges;
|
NSMutableArray *ranges;
|
||||||
NSCalendarDate *firStart, *startDate, *endDate, *currentStartDate, *currentEndDate;
|
NSCalendarDate *firStart, *startDate, *endDate, *currentStartDate, *currentEndDate;
|
||||||
|
|
|
@ -495,8 +495,7 @@ Class SOGoContactSourceFolderK;
|
||||||
ascending: YES];
|
ascending: YES];
|
||||||
descriptors = [NSArray arrayWithObjects: commonNameDescriptor, nil];
|
descriptors = [NSArray arrayWithObjects: commonNameDescriptor, nil];
|
||||||
[commonNameDescriptor release];
|
[commonNameDescriptor release];
|
||||||
sortedContacts = [[uniqueContacts allValues]
|
sortedContacts = [[uniqueContacts allValues] sortedArrayUsingDescriptors: descriptors];
|
||||||
sortedArrayUsingDescriptors: descriptors];
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
sortedContacts = [NSArray array];
|
sortedContacts = [NSArray array];
|
||||||
|
|
|
@ -433,10 +433,9 @@ static NSString *inboxFolderName = @"INBOX";
|
||||||
[folderPaths addObject: namespace];
|
[folderPaths addObject: namespace];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
[folderPaths
|
[folderPaths sortUsingSelector: @selector (localizedCaseInsensitiveCompare:)];
|
||||||
sortUsingSelector: @selector (localizedCaseInsensitiveCompare:)];
|
|
||||||
[folderPaths replaceObjectsInRange: NSMakeRange (0, 0)
|
[folderPaths replaceObjectsInRange: NSMakeRange (0, 0)
|
||||||
withObjectsFromArray: mainFolders];
|
withObjectsFromArray: mainFolders];
|
||||||
|
|
||||||
return folderPaths;
|
return folderPaths;
|
||||||
}
|
}
|
||||||
|
|
|
@ -213,7 +213,6 @@ static BOOL debugOn = NO;
|
||||||
{
|
{
|
||||||
NGMimeMessage *m;
|
NGMimeMessage *m;
|
||||||
id part;
|
id part;
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
m = [[o content] messageFromOpaqueSignedData];
|
m = [[o content] messageFromOpaqueSignedData];
|
||||||
|
@ -222,7 +221,7 @@ static BOOL debugOn = NO;
|
||||||
for (i = 0; i < [[self bodyPartPath] count]; i++)
|
for (i = 0; i < [[self bodyPartPath] count]; i++)
|
||||||
{
|
{
|
||||||
nbr = [[[self bodyPartPath] objectAtIndex: i] intValue]-1;
|
nbr = [[[self bodyPartPath] objectAtIndex: i] intValue]-1;
|
||||||
part = [[part parts] objectAtIndex: nbr];;
|
part = [[part parts] objectAtIndex: nbr];
|
||||||
}
|
}
|
||||||
|
|
||||||
part = [[part parts] objectAtIndex: ([key intValue]-1)];
|
part = [[part parts] objectAtIndex: ([key intValue]-1)];
|
||||||
|
|
|
@ -1239,10 +1239,9 @@ static Class NSNullK;
|
||||||
- (NSArray *) fetchUsersMatching: (NSString *) filter
|
- (NSArray *) fetchUsersMatching: (NSString *) filter
|
||||||
inDomain: (NSString *) domain
|
inDomain: (NSString *) domain
|
||||||
{
|
{
|
||||||
return [self
|
return [self _fetchEntriesInSources: [self authenticationSourceIDsInDomain: domain]
|
||||||
_fetchEntriesInSources: [self authenticationSourceIDsInDomain: domain]
|
matching: filter
|
||||||
matching: filter
|
inDomain: domain];
|
||||||
inDomain: domain];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSString *) getLoginForDN: (NSString *) theDN
|
- (NSString *) getLoginForDN: (NSString *) theDN
|
||||||
|
|
|
@ -48,7 +48,7 @@
|
||||||
s = [[info objectForKey:@"disposition"] objectForKey: @"type"];
|
s = [[info objectForKey:@"disposition"] objectForKey: @"type"];
|
||||||
|
|
||||||
shouldDisplay = (s && ([s caseInsensitiveCompare: @"ATTACHMENT"] == NSOrderedSame));
|
shouldDisplay = (s && ([s caseInsensitiveCompare: @"ATTACHMENT"] == NSOrderedSame));
|
||||||
|
|
||||||
if (!shouldDisplay && !textPart)
|
if (!shouldDisplay && !textPart)
|
||||||
shouldDisplay = ([[info objectForKey: @"bodyId"] length] ? YES : NO);
|
shouldDisplay = ([[info objectForKey: @"bodyId"] length] ? YES : NO);
|
||||||
|
|
||||||
|
@ -199,7 +199,7 @@ static BOOL showNamedTextAttachmentsInline = NO;
|
||||||
return [self signedViewer];
|
return [self signedViewer];
|
||||||
else if ([st isEqualToString: @"alternative"])
|
else if ([st isEqualToString: @"alternative"])
|
||||||
return [self alternativeViewer];
|
return [self alternativeViewer];
|
||||||
|
|
||||||
if ([st isEqualToString: @"report"])
|
if ([st isEqualToString: @"report"])
|
||||||
/* this is used by mail-delivery reports */
|
/* this is used by mail-delivery reports */
|
||||||
return [self mixedViewer];
|
return [self mixedViewer];
|
||||||
|
@ -209,15 +209,15 @@ static BOOL showNamedTextAttachmentsInline = NO;
|
||||||
if ([st isEqualToString: @"plain"] || [st isEqualToString: @"html"]) {
|
if ([st isEqualToString: @"plain"] || [st isEqualToString: @"html"]) {
|
||||||
if (!showNamedTextAttachmentsInline && [self _shouldDisplayAsAttachment: _info textPart: YES])
|
if (!showNamedTextAttachmentsInline && [self _shouldDisplayAsAttachment: _info textPart: YES])
|
||||||
return [self linkViewer];
|
return [self linkViewer];
|
||||||
|
|
||||||
return [st isEqualToString: @"html"]
|
return [st isEqualToString: @"html"]
|
||||||
? [self htmlViewer] : [self textViewer];
|
? [self htmlViewer] : [self textViewer];
|
||||||
}
|
}
|
||||||
|
|
||||||
if ([st isEqualToString:@"calendar"])
|
if ([st isEqualToString:@"calendar"])
|
||||||
return [self iCalViewer];
|
return [self iCalViewer];
|
||||||
}
|
}
|
||||||
|
|
||||||
// TIFF files aren't well-supported and Thunderbird sometimes send PDF
|
// TIFF files aren't well-supported and Thunderbird sometimes send PDF
|
||||||
// files over as image/pdf !
|
// files over as image/pdf !
|
||||||
if ([mt isEqualToString: @"image"] &&
|
if ([mt isEqualToString: @"image"] &&
|
||||||
|
@ -225,22 +225,22 @@ static BOOL showNamedTextAttachmentsInline = NO;
|
||||||
{
|
{
|
||||||
if ([self _shouldDisplayAsAttachment: _info textPart: NO] || [st isEqualToString: @"svg+xml"])
|
if ([self _shouldDisplayAsAttachment: _info textPart: NO] || [st isEqualToString: @"svg+xml"])
|
||||||
return [self linkViewer];
|
return [self linkViewer];
|
||||||
|
|
||||||
return [self imageViewer];
|
return [self imageViewer];
|
||||||
}
|
}
|
||||||
|
|
||||||
if ([mt isEqualToString: @"message"] && [st isEqualToString: @"rfc822"])
|
if ([mt isEqualToString: @"message"] && [st isEqualToString: @"rfc822"])
|
||||||
return [self messageViewer];
|
return [self messageViewer];
|
||||||
|
|
||||||
if ([mt isEqualToString: @"message"] &&
|
if ([mt isEqualToString: @"message"] &&
|
||||||
[st isEqualToString: @"delivery-status"]) {
|
[st isEqualToString: @"delivery-status"]) {
|
||||||
/*
|
/*
|
||||||
Content-Description: Delivery error report
|
Content-Description: Delivery error report
|
||||||
Content-Type: message/delivery-status
|
Content-Type: message/delivery-status
|
||||||
|
|
||||||
Reporting-MTA: dns; mail.opengroupware.org
|
Reporting-MTA: dns; mail.opengroupware.org
|
||||||
Arrival-Date: Mon, 18 Jul 2005 12:08:43 +0200 (CEST)
|
Arrival-Date: Mon, 18 Jul 2005 12:08:43 +0200 (CEST)
|
||||||
|
|
||||||
Final-Recipient: rfc822; ioioi@plop.com
|
Final-Recipient: rfc822; ioioi@plop.com
|
||||||
Action: failed
|
Action: failed
|
||||||
Status: 5.0.0
|
Status: 5.0.0
|
||||||
|
@ -317,10 +317,10 @@ static NSString *MRK = @"UIxMailRenderingContext";
|
||||||
- (UIxMailRenderingContext *) popMailRenderingContext
|
- (UIxMailRenderingContext *) popMailRenderingContext
|
||||||
{
|
{
|
||||||
UIxMailRenderingContext *mctx;
|
UIxMailRenderingContext *mctx;
|
||||||
|
|
||||||
if ((mctx = [self objectForKey:MRK]) == nil)
|
if ((mctx = [self objectForKey:MRK]) == nil)
|
||||||
return nil;
|
return nil;
|
||||||
|
|
||||||
mctx = [[mctx retain] autorelease];
|
mctx = [[mctx retain] autorelease];
|
||||||
[self removeObjectForKey:MRK];
|
[self removeObjectForKey:MRK];
|
||||||
return mctx;
|
return mctx;
|
||||||
|
|
Loading…
Reference in New Issue