enable queue menu items for queued seeds

This commit is contained in:
Mitchell Livingston 2007-01-09 14:58:05 +00:00
parent c0174bd8d5
commit f23d2aa950
1 changed files with 4 additions and 4 deletions

View File

@ -2355,13 +2355,13 @@ static void sleepCallBack(void * controller, io_service_t y, natural_t messageTy
//enable resume all waiting item
if (action == @selector(resumeWaitingTorrents:))
{
if (![fDefaults boolForKey: @"Queue"])
if (![fDefaults boolForKey: @"Queue"] && ![fDefaults boolForKey: @"QueueSeed"])
return NO;
Torrent * torrent;
NSEnumerator * enumerator = [fTorrents objectEnumerator];
while ((torrent = [enumerator nextObject]))
if ([torrent waitingToStart])
if (![torrent isActive] && [torrent waitingToStart])
return YES;
return NO;
}
@ -2369,14 +2369,14 @@ static void sleepCallBack(void * controller, io_service_t y, natural_t messageTy
//enable resume selected waiting item
if (action == @selector(resumeSelectedTorrentsNoWait:))
{
if (![fDefaults boolForKey: @"Queue"])
if (![fDefaults boolForKey: @"Queue"] && ![fDefaults boolForKey: @"QueueSeed"])
return NO;
NSEnumerator * enumerator = [[fDisplayedTorrents objectsAtIndexes: [fTableView selectedRowIndexes]] objectEnumerator];
Torrent * torrent;
while ((torrent = [enumerator nextObject]))
{
if ([torrent isPaused] && [torrent progress] < 1.0)
if (![torrent isActive])
return YES;
}
return NO;