Changeset 23540
- Timestamp:
- 05/21/2008 08:15:44 PM (6 months ago)
- Files:
-
- trunk/Source/AIAbstractLogViewerWindowController.h (modified) (1 diff)
- trunk/Source/AIAbstractLogViewerWindowController.m (modified) (3 diffs)
- trunk/Source/AIChatLog.m (modified) (1 diff)
- trunk/Source/AILoggerPlugin.m (modified) (1 diff)
- trunk/Source/AILogToGroup.m (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/Source/AIAbstractLogViewerWindowController.h
r23076 r23540 191 191 192 192 @end 193 194 NSString *handleSpecialCasesForUIDAndServiceClass(NSString *contactUID, NSString *serviceClass); trunk/Source/AIAbstractLogViewerWindowController.m
r23500 r23540 312 312 NSEnumerator *toEnum; 313 313 AILogToGroup *currentToGroup; 314 NSString *serviceClass = [logFromGroup serviceClass];315 314 316 315 //Add the 'to' for each grouping on this account … … 320 319 321 320 if ((currentTo = [currentToGroup to])) { 321 NSString *serviceClass = [currentToGroup serviceClass]; 322 322 AIListObject *listObject = ((serviceClass && currentTo) ? 323 323 [[adium contactController] existingListObjectWithUniqueID:[AIListObject internalObjectIDForServiceID:serviceClass … … 2719 2719 } 2720 2720 2721 #pragma Transcript services special-casing 2722 NSString *handleSpecialCasesForUIDAndServiceClass(NSString *contactUID, NSString *serviceClass) 2723 { 2724 /* Jabber and its specified derivative services need special handling; 2725 * this is cross-contamination from ESPurpleJabberAccount. 2726 */ 2727 if ([serviceClass isEqualToString:@"Jabber"] || 2728 [serviceClass isEqualToString:@"GTalk"] || 2729 [serviceClass isEqualToString:@"LiveJournal"]) { 2730 2731 if ([contactUID hasSuffix:@"@gmail.com"] || 2732 [contactUID hasSuffix:@"@googlemail.com"]) { 2733 serviceClass = @"GTalk"; 2734 2735 } else if ([contactUID hasSuffix:@"@livejournal.com"]){ 2736 serviceClass = @"LiveJournal"; 2737 2738 } else { 2739 serviceClass = @"Jabber"; 2740 } 2741 2742 /* OSCAR and its specified derivative services need special handling; 2743 * this is cross-contamination from CBPurpleOscarAccount. 2744 */ 2745 } else if ([serviceClass isEqualToString:@"AIM"] || 2746 [serviceClass isEqualToString:@"ICQ"] || 2747 [serviceClass isEqualToString:@"Mac"]) { 2748 const char firstCharacter = ([contactUID length] ? [contactUID characterAtIndex:0] : '\0'); 2749 2750 //Determine service based on UID 2751 if ([contactUID hasSuffix:@"@mac.com"]) { 2752 serviceClass = @"Mac"; 2753 } else if (firstCharacter && (firstCharacter >= '0' && firstCharacter <= '9')) { 2754 serviceClass = @"ICQ"; 2755 } else { 2756 serviceClass = @"AIM"; 2757 } 2758 } 2759 2760 return serviceClass; 2761 } 2762 2721 2763 @end trunk/Source/AIChatLog.m
r19643 r23540 50 50 51 51 if ([serviceAndFromUIDArray count] >= 2) { 52 myServiceClass = [serviceAndFromUIDArray objectAtIndex:0];52 myServiceClass = handleSpecialCasesForUIDAndServiceClass(toUID, [serviceAndFromUIDArray objectAtIndex:0]); 53 53 54 54 //Use substringFromIndex so we include the rest of the string in the case of a UID with a . in it trunk/Source/AILoggerPlugin.m
r23504 r23540 1392 1392 1393 1393 @end 1394 1395 trunk/Source/AILogToGroup.m
r23500 r23540 18 18 #import "AILogToGroup.h" 19 19 #import "AIChatLog.h" 20 #import "AIAbstractLogViewerWindowController.h" 20 21 #import <AIUtilities/AIFileManagerAdditions.h> 21 22 … … 35 36 from = [inFrom retain]; 36 37 to = [inTo retain]; 37 serviceClass = [ inServiceClassretain];38 serviceClass = [handleSpecialCasesForUIDAndServiceClass(to, inServiceClass) retain]; 38 39 logDict = nil; 39 40 partialLogDict = nil;