diff --git a/macosx/English.lproj/InfoWindow.nib/keyedobjects.nib b/macosx/English.lproj/InfoWindow.nib/keyedobjects.nib index 09c18f1d3..3c59084a3 100644 Binary files a/macosx/English.lproj/InfoWindow.nib/keyedobjects.nib and b/macosx/English.lproj/InfoWindow.nib/keyedobjects.nib differ diff --git a/macosx/InfoWindowController.m b/macosx/InfoWindowController.m index 1fc161800..1b6d78551 100644 --- a/macosx/InfoWindowController.m +++ b/macosx/InfoWindowController.m @@ -95,8 +95,10 @@ NSBrowserCell * browserCell = [[[NSBrowserCell alloc] init] autorelease]; [browserCell setLeaf: YES]; [[fFileOutline tableColumnWithIdentifier: @"Name"] setDataCell: browserCell]; + [fFileOutline setDoubleAction: @selector(revealFile:)]; + //set blank inspector [self updateInfoForTorrents: [NSArray array]]; } @@ -263,13 +265,13 @@ [fFiles release]; fFiles = [[torrent fileList] retain]; - #warning change! - if ([fFiles count] > 1) - [fFileTableStatusField setStringValue: [NSString stringWithFormat: NSLocalizedString(@"%d files", - "Inspector -> Files tab -> bottom text (number of files)"), [fFiles count]]]; + int fileCount = [torrent fileCount]; + if (fileCount != 1) + [fFileTableStatusField setStringValue: [NSString stringWithFormat: NSLocalizedString(@"%d files total", + "Inspector -> Files tab -> bottom text (number of files)"), fileCount]]; else - [fFileTableStatusField setStringValue: [NSString stringWithFormat: NSLocalizedString(@"%d file", - "Inspector -> Files tab -> bottom text (number of files)"), [fFiles count]]]; + [fFileTableStatusField setStringValue: NSLocalizedString(@"1 file total", + "Inspector -> Files tab -> bottom text (number of files)")]; } //update stats and settings diff --git a/macosx/Torrent.h b/macosx/Torrent.h index 1e2deca3a..1f75416e2 100644 --- a/macosx/Torrent.h +++ b/macosx/Torrent.h @@ -180,6 +180,7 @@ - (void) setOrderValue: (int) orderValue; - (NSArray *) fileList; +- (int) fileCount; - (NSDate *) date; - (NSNumber *) stateSortKey; diff --git a/macosx/Torrent.m b/macosx/Torrent.m index 605f256d1..eb152cb6c 100644 --- a/macosx/Torrent.m +++ b/macosx/Torrent.m @@ -1066,7 +1066,7 @@ static uint32_t kRed = BE(0xFF6450FF), //255, 100, 80 - (NSArray *) fileList { - int count = fInfo->fileCount, i; + int count = [self fileCount], i; tr_file_t file; NSMutableArray * files = [NSMutableArray array]; @@ -1082,6 +1082,11 @@ static uint32_t kRed = BE(0xFF6450FF), //255, 100, 80 return files; } +- (int) fileCount +{ + return fInfo->fileCount; +} + - (NSDate *) date { return fDate;