Changeset 7755
- Timestamp:
- Jan 19, 2009, 10:16:11 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/macosx/Controller.m
r7753 r7755 3944 3944 3945 3945 NSRect allRect = [fNoFilterButton frame]; 3946 3947 3946 NSRect activeRect = [fActiveFilterButton frame]; 3948 activeRect.origin.x = NSMaxX(allRect) + 1.0;3949 3950 3947 NSRect downloadRect = [fDownloadFilterButton frame]; 3951 downloadRect.origin.x = NSMaxX(activeRect) + 1.0;3952 3953 3948 NSRect seedRect = [fSeedFilterButton frame]; 3954 seedRect.origin.x = NSMaxX(downloadRect) + 1.0;3955 3956 3949 NSRect pauseRect = [fPauseFilterButton frame]; 3957 pauseRect.origin.x = NSMaxX(seedRect) + 1.0;3958 3950 3959 3951 //size search filter to not overlap buttons … … 3980 3972 3981 3973 //decrease button widths proportionally 3982 const NSInteger all = NSWidth(allRect) * (allowedWidth / currentTotal); 3983 const NSInteger active = NSWidth(activeRect) * (allowedWidth / currentTotal); 3984 const NSInteger download = NSWidth(downloadRect) * (allowedWidth / currentTotal); 3985 const NSInteger seed = NSWidth(seedRect) * (allowedWidth / currentTotal); 3986 const NSInteger paused = NSWidth(pauseRect) * (allowedWidth / currentTotal); 3987 3988 allRect.size.width = all; 3989 3990 activeRect.size.width = active; 3991 activeRect.origin.x = NSMaxX(allRect) + 1.0; 3992 3993 downloadRect.size.width = download; 3994 downloadRect.origin.x = NSMaxX(activeRect) + 1.0; 3995 3996 seedRect.size.width = seed; 3997 seedRect.origin.x = NSMaxX(downloadRect) + 1.0; 3998 3999 pauseRect.size.width = paused; 4000 pauseRect.origin.x = NSMaxX(seedRect) + 1.0; 3974 allRect.size.width = NSWidth(allRect) * (allowedWidth / currentTotal); 3975 activeRect.size.width = NSWidth(activeRect) * (allowedWidth / currentTotal); 3976 downloadRect.size.width = NSWidth(downloadRect) * (allowedWidth / currentTotal); 3977 seedRect.size.width = NSWidth(seedRect) * (allowedWidth / currentTotal); 3978 pauseRect.size.width = NSWidth(pauseRect) * (allowedWidth / currentTotal); 4001 3979 } 4002 3980 else; 3981 3982 activeRect.origin.x = NSMaxX(allRect) + 1.0; 3983 downloadRect.origin.x = NSMaxX(activeRect) + 1.0; 3984 seedRect.origin.x = NSMaxX(downloadRect) + 1.0; 3985 pauseRect.origin.x = NSMaxX(seedRect) + 1.0; 4003 3986 4004 3987 [fNoFilterButton setFrame: allRect];
Note: See TracChangeset
for help on using the changeset viewer.