Changeset 2335 for trunk/macosx/Torrent.m
- Timestamp:
- Jul 13, 2007, 2:57:20 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/macosx/Torrent.m
r2327 r2335 148 148 [NSNumber numberWithInt: fDownloadLimit], @"DownloadLimit", 149 149 [NSNumber numberWithBool: fWaitToStart], @"WaitToStart", 150 [self orderValue], @"OrderValue", 151 nil]; 150 [self orderValue], @"OrderValue", nil]; 152 151 153 152 if (fIncompleteFolder) … … 1314 1313 - (void) setFileCheckState: (int) state forIndexes: (NSIndexSet *) indexSet 1315 1314 { 1316 #warning multiples 1317 int index; 1315 int count = [indexSet count], i = 0, index; 1316 int * files = malloc(count * sizeof(int)); 1317 1318 1318 for (index = [indexSet firstIndex]; index != NSNotFound; index = [indexSet indexGreaterThanIndex: index]) 1319 tr_torrentSetFileDL(fHandle, index, state != NSOffState); 1319 { 1320 files[i] = index; 1321 i++; 1322 } 1323 tr_torrentSetFileDLs(fHandle, files, count, state != NSOffState); 1324 free(files); 1320 1325 1321 1326 [self update]; … … 1326 1331 - (void) setFilePriority: (int) priority forIndexes: (NSIndexSet *) indexSet 1327 1332 { 1328 #warning multiples 1329 int index; 1333 int count = [indexSet count], i = 0, index; 1334 int * files = malloc(count * sizeof(int)); 1335 1330 1336 for (index = [indexSet firstIndex]; index != NSNotFound; index = [indexSet indexGreaterThanIndex: index]) 1331 tr_torrentSetFilePriority(fHandle, index, priority); 1337 { 1338 files[i] = index; 1339 i++; 1340 } 1341 1342 tr_torrentSetFilePriorities(fHandle, files, count, priority); 1343 free(files); 1332 1344 } 1333 1345
Note: See TracChangeset
for help on using the changeset viewer.