fix Quick Look from the file inspector

This commit is contained in:
Mitchell Livingston
2009-10-22 00:10:41 +00:00
parent 236bdc594f
commit 9c21268250
3 changed files with 14 additions and 15 deletions

View File

@@ -1136,7 +1136,7 @@ typedef enum
{
FileListNode * item = [fileOutlineView itemAtRow: i];
if ([self canQuickLookFile: item])
[urlArray addObject: [torrent fileLocation: item]];
[urlArray addObject: [NSURL fileURLWithPath: [torrent fileLocation: item]]];
}
return urlArray;
@@ -1665,7 +1665,7 @@ typedef enum
- (BOOL) canQuickLookFile: (FileListNode *) item
{
Torrent * torrent = [fTorrents objectAtIndex: 0];
return [torrent fileLocation: item] != nil && ([item isFolder] || [torrent fileProgress: item] >= 1.0);
return ([item isFolder] || [torrent fileProgress: item] >= 1.0) && [torrent fileLocation: item];
}
#warning doesn't like blank addresses