Changeset 13256
- Timestamp:
- Mar 18, 2012, 2:33:50 PM (11 years ago)
- Location:
- trunk/macosx
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/macosx/Controller.h
r13254 r13256 62 62 NSUserDefaults * fDefaults; 63 63 64 NSString * fConfigDirectory; 65 64 66 IBOutlet NSWindow * fWindow; 65 67 DragOverlayWindow * fOverlayWindow; -
trunk/macosx/Controller.m
r13255 r13256 325 325 tr_bencFree(&settings); 326 326 327 fConfigDirectory = [[NSString alloc] initWithUTF8String: configDir]; 328 327 329 [NSApp setDelegate: self]; 328 330 … … 445 447 446 448 //load previous transfers 447 NS URL * historyURL = [[[[[NSFileManager defaultManager] URLsForDirectory: NSApplicationSupportDirectory inDomains: NSUserDomainMask] objectAtIndex: 0] URLByAppendingPathComponent: @"Transmission"] URLByAppendingPathComponent: TRANSFER_PLIST];448 NSArray * history = [NSArray arrayWithContentsOf URL: historyURL];449 NSString * historyFile = [fConfigDirectory stringByAppendingPathComponent: TRANSFER_PLIST]; 450 NSArray * history = [NSArray arrayWithContentsOfFile: historyFile]; 449 451 if (!history) 450 452 { … … 724 726 725 727 [fPreviewPanel release]; 728 729 [fConfigDirectory release]; 726 730 727 731 //complete cleanup … … 1904 1908 [history addObject: [torrent history]]; 1905 1909 1906 NS URL * historyURL = [[[[[NSFileManager defaultManager] URLsForDirectory: NSApplicationSupportDirectory inDomains: NSUserDomainMask] objectAtIndex: 0] URLByAppendingPathComponent: @"Transmission"] URLByAppendingPathComponent: TRANSFER_PLIST];1907 [history writeTo URL: historyURLatomically: YES];1910 NSString * historyFile = [fConfigDirectory stringByAppendingPathComponent: TRANSFER_PLIST]; 1911 [history writeToFile: historyFile atomically: YES]; 1908 1912 } 1909 1913
Note: See TracChangeset
for help on using the changeset viewer.