Changeset 655
- Timestamp:
- Jul 22, 2006, 4:38:05 PM (17 years ago)
- Location:
- trunk
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Transmission.xcodeproj/project.pbxproj
r651 r655 936 936 GCC_VERSION_ppc = 3.3; 937 937 MACOSX_DEPLOYMENT_TARGET_i386 = 10.4; 938 MACOSX_DEPLOYMENT_TARGET_ppc = 10. 2;938 MACOSX_DEPLOYMENT_TARGET_ppc = 10.3; 939 939 SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk; 940 940 }; -
trunk/macosx/BarButton.m
r648 r655 51 51 mainSize = NSMakeSize(buttonSize.width - endSize.width * 2.0, endSize.height); 52 52 NSPoint leftPoint = NSMakePoint(0, 0), 53 mainPoint = NSMakePoint(endSize.width, 0),54 rightPoint = NSMakePoint(buttonSize.width -endSize.width, 0);53 rightPoint = NSMakePoint(buttonSize.width - endSize.width, 0), 54 mainPoint = NSMakePoint(endSize.width, 0); 55 55 56 56 [mainOver setScalesWhenResized: YES]; … … 199 199 [highlightedAttributes release]; 200 200 [highlightedDimAttributes release]; 201 202 //NSLog(@"%@ %f", text, textRect.width);203 201 } 204 202 -
trunk/macosx/Controller.h
r653 r655 179 179 - (void) toggleAdvancedBar: (id) sender; 180 180 181 - (void) setWindowSizeToFit; 182 181 183 - (void) showMainWindow: (id) sender; 182 184 - (void) linkHomepage: (id) sender; -
trunk/macosx/Controller.m
r654 r655 307 307 name: @"RatioGlobalChange" object: nil]; 308 308 309 [nc addObserver: self selector: @selector(autoImportChange:) 310 name: @"AutoImportSettingChange" object: nil]; 311 312 [nc addObserver: self selector: @selector(setWindowSizeToFit) 313 name: @"AutoSizeSettingChange" object: nil]; 314 309 315 //check to start another because of stopped torrent 310 316 [nc addObserver: self selector: @selector(checkWaitingForStopped:) … … 326 332 [nc addObserver: self selector: @selector(reloadInspectorSettings:) 327 333 name: @"TorrentSettingChange" object: nil]; 328 329 //reset auto import330 [nc addObserver: self selector: @selector(autoImportChange:)331 name: @"AutoImportSettingChange" object: nil];332 334 333 335 //timer to update the interface every second … … 348 350 349 351 [self applyFilter: nil]; 352 [self setWindowSizeToFit]; 350 353 351 354 [fWindow makeKeyAndOrderFront: nil]; … … 508 511 [self updateUI: nil]; 509 512 [self applyFilter: nil]; 513 [self setWindowSizeToFit]; 514 510 515 [self updateTorrentHistory]; 511 516 } … … 733 738 [self torrentNumberChanged]; 734 739 [fTableView deselectAll: nil]; 740 735 741 [self updateUI: nil]; 742 [self setWindowSizeToFit]; 743 736 744 [self updateTorrentHistory]; 737 745 } … … 1589 1597 [fWindow setContentMinSize: contentMinSize]; 1590 1598 1599 [self setWindowSizeToFit]; 1600 1591 1601 //resize for larger min height 1592 1602 if (!makeSmall && contentSize.height < contentMinSize.height) … … 2125 2135 } 2126 2136 2137 - (void) setWindowSizeToFit 2138 { 2139 if (![fDefaults boolForKey: @"AutoSize"]) 2140 return; 2141 2142 NSRect frame = [fWindow frame]; 2143 float newHeight = frame.size.height - [fScrollView frame].size.height 2144 + [fTorrents count] * ([fTableView rowHeight] + [fTableView intercellSpacing].height); 2145 2146 float minHeight = [fWindow minSize].height; 2147 if (newHeight < minHeight) 2148 newHeight = minHeight; 2149 2150 frame.origin.y -= (newHeight - frame.size.height); 2151 frame.size.height = newHeight; 2152 2153 [fWindow setFrame: frame display: YES animate: YES]; 2154 } 2155 2127 2156 - (void) showMainWindow: (id) sender 2128 2157 { … … 2155 2184 } 2156 2185 2186 - (NSSize) windowWillResize: (NSWindow *) sender toSize: (NSSize) proposedFrameSize 2187 { 2188 if ([fDefaults boolForKey: @"AutoSize"]) 2189 proposedFrameSize.height = [fWindow frame].size.height; 2190 return proposedFrameSize; 2191 } 2192 2157 2193 - (void) windowDidResize: (NSNotification *) notification 2158 2194 { -
trunk/macosx/Defaults.plist
r576 r655 7 7 <key>AutoImportDirectory</key> 8 8 <string>~/Desktop</string> 9 <key>AutoSize</key> 10 <false/> 9 11 <key>BadgeDownloadRate</key> 10 12 <false/> -
trunk/macosx/English.lproj/PrefsWindow.nib/classes.nib
r539 r655 8 8 importFolderSheetShow = id; 9 9 setAutoImport = id; 10 setAutoSize = id; 10 11 setBadge = id; 11 12 setDownloadLocation = id; … … 26 27 OUTLETS = { 27 28 fAutoImportCheck = NSButton; 29 fAutoSizeCheck = NSButton; 28 30 fBadgeDownloadRateCheck = NSButton; 29 31 fBadgeUploadRateCheck = NSButton; -
trunk/macosx/English.lproj/PrefsWindow.nib/info.nib
r603 r655 4 4 <dict> 5 5 <key>IBDocumentLocation</key> 6 <string> 69 61356 240 0 0 1152 842 </string>6 <string>49 70 356 240 0 0 1152 842 </string> 7 7 <key>IBEditorPositions</key> 8 8 <dict> 9 9 <key>153</key> 10 10 <string>299 469 554 217 0 0 1152 842 </string> 11 <key>28</key> 12 <string>85 426 553 285 0 0 1152 842 </string> 11 13 <key>41</key> 12 14 <string>299 417 554 321 0 0 1152 842 </string> … … 16 18 <key>IBOpenObjects</key> 17 19 <array> 18 <integer> 41</integer>20 <integer>28</integer> 19 21 </array> 20 22 <key>IBSystem Version</key> -
trunk/macosx/PrefsController.h
r539 r655 39 39 * fBadgeDownloadRateCheck, * fBadgeUploadRateCheck, 40 40 * fCopyTorrentCheck, * fDeleteOriginalTorrentCheck, 41 * fAutoImportCheck ;41 * fAutoImportCheck, * fAutoSizeCheck; 42 42 43 43 IBOutlet NSPopUpButton * fUpdatePopUp; … … 88 88 - (void) importFolderSheetShow: (id) sender; 89 89 90 - (void) setAutoSize: (id) sender; 91 90 92 - (void) setRatio: (id) sender; 91 93 - (void) setRatioCheck: (id) sender; -
trunk/macosx/PrefsController.m
r558 r655 112 112 [fImportFolderPopUp setEnabled: autoImport]; 113 113 114 //set auto size 115 [fAutoSizeCheck setState: [fDefaults boolForKey: @"AutoSize"]]; 116 114 117 //set bind port 115 118 int bindPort = [fDefaults integerForKey: @"BindPort"]; … … 632 635 modalForWindow: [self window] modalDelegate: self didEndSelector: 633 636 @selector(importFolderSheetClosed:returnCode:contextInfo:) contextInfo: nil]; 637 } 638 639 - (void) setAutoSize: (id) sender 640 { 641 [fDefaults setBool: [sender state] forKey: @"AutoSize"]; 642 643 [[NSNotificationCenter defaultCenter] postNotificationName: @"AutoSizeSettingChange" object: self]; 634 644 } 635 645
Note: See TracChangeset
for help on using the changeset viewer.