handle all settings changed by rpc (previously download location was missing)

This commit is contained in:
Mitchell Livingston
2008-06-05 15:22:18 +00:00
parent 4951ba05d0
commit bd2ad5ca97
4 changed files with 8 additions and 9 deletions
+2 -4
View File
@@ -1553,10 +1553,8 @@ typedef enum
[fTrackers removeObjectsAtIndexes: indexes];
if (![torrent updateAllTrackersForRemove: fTrackers])
NSBeep();
else
[fTrackerTable deselectAll: self];
[torrent updateAllTrackersForRemove: fTrackers];
[fTrackerTable deselectAll: self];
//reset table with either new or old value
[fTrackers release];
+4 -1
View File
@@ -810,7 +810,8 @@
[fDefaults setBool: encryptionMode == TR_ENCRYPTION_PREFERRED forKey: @"EncryptionPrefer"];
//download directory
#warning missing!
NSString * downloadLocation = [[NSString stringWithUTF8String: tr_sessionGetDownloadDir(fHandle)] stringByStandardizingPath];
[fDefaults setObject: downloadLocation forKey: @"DownloadFolder"];
//peers
uint16_t peersTotal = tr_sessionGetPeerLimit(fHandle);
@@ -850,6 +851,8 @@
{
//encryption handled by bindings
//download directory handled by bindings
[fPeersGlobalField setIntValue: peersTotal];
//pex handled by bindings
+1 -1
View File
@@ -151,7 +151,7 @@ typedef enum
- (NSMutableArray *) allTrackers: (BOOL) separators;
- (BOOL) updateAllTrackersForAdd: (NSMutableArray *) trackers;
- (BOOL) updateAllTrackersForRemove: (NSMutableArray *) trackers;
- (void) updateAllTrackersForRemove: (NSMutableArray *) trackers;
- (BOOL) hasAddedTrackers;
- (NSString *) comment;
+1 -3
View File
@@ -819,15 +819,13 @@ void completenessChangeCallback(tr_torrent * torrent, cp_status_t status, void *
return YES;
}
- (BOOL) updateAllTrackersForRemove: (NSMutableArray *) trackers
- (void) updateAllTrackersForRemove: (NSMutableArray *) trackers
{
//check if no user-added groups
if ([[trackers objectAtIndex: 0] intValue] != 0)
fAddedTrackers = NO;
[self updateAllTrackers: trackers];
return YES;
}
- (BOOL) hasAddedTrackers