Changeset 491


Ignore:
Timestamp:
Jul 1, 2006, 12:29:26 AM (16 years ago)
Author:
livings124
Message:

The Almighty Turtle!

Speed Limit can now be accessed from the main window, among smaller changes.

Location:
trunk
Files:
2 added
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/Transmission.xcodeproj/project.pbxproj

    r486 r491  
    110110                A2D0E0490A54A97C003C72CF /* Bandwidth.png in Resources */ = {isa = PBXBuildFile; fileRef = A2D0E0480A54A97C003C72CF /* Bandwidth.png */; };
    111111                A2F40AE40A361C00006B8288 /* Transmission.icns in Resources */ = {isa = PBXBuildFile; fileRef = 4D2784360905709500687951 /* Transmission.icns */; };
     112                A2F6DB080A55F31C0058D1E5 /* SpeedLimitButtonPressed.tiff in Resources */ = {isa = PBXBuildFile; fileRef = A2F6DB060A55F31C0058D1E5 /* SpeedLimitButtonPressed.tiff */; };
     113                A2F6DB090A55F31C0058D1E5 /* SpeedLimitButton.png in Resources */ = {isa = PBXBuildFile; fileRef = A2F6DB070A55F31C0058D1E5 /* SpeedLimitButton.png */; };
    112114                A2F8951F0A2D4BA500ED2127 /* Credits.rtf in Resources */ = {isa = PBXBuildFile; fileRef = A2F8951E0A2D4BA500ED2127 /* Credits.rtf */; };
    113115/* End PBXBuildFile section */
     
    291293                A2C655640A04FEDC00E9FD82 /* BottomBorder.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = BottomBorder.png; path = macosx/Images/BottomBorder.png; sourceTree = "<group>"; };
    292294                A2D0E0480A54A97C003C72CF /* Bandwidth.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = Bandwidth.png; path = macosx/Images/Bandwidth.png; sourceTree = "<group>"; };
     295                A2F6DB060A55F31C0058D1E5 /* SpeedLimitButtonPressed.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; name = SpeedLimitButtonPressed.tiff; path = macosx/Images/SpeedLimitButtonPressed.tiff; sourceTree = "<group>"; };
     296                A2F6DB070A55F31C0058D1E5 /* SpeedLimitButton.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = SpeedLimitButton.png; path = macosx/Images/SpeedLimitButton.png; sourceTree = "<group>"; };
    293297                A2F8951E0A2D4BA500ED2127 /* Credits.rtf */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; name = Credits.rtf; path = macosx/Credits.rtf; sourceTree = "<group>"; };
    294298/* End PBXFileReference section */
     
    429433                                A28DBADB0A33C1D800F4B4A7 /* ActionButton.png */,
    430434                                A2173E1B0A33C1B300B0D8AB /* ActionButtonPressed.png */,
     435                                A2F6DB060A55F31C0058D1E5 /* SpeedLimitButtonPressed.tiff */,
     436                                A2F6DB070A55F31C0058D1E5 /* SpeedLimitButton.png */,
    431437                                A27A53560A06A76400E1F16F /* StatusSep.png */,
    432438                                A27A53650A06AEDB00E1F16F /* StatusBorder.png */,
     
    681687                                A28C43F40A4A5D700091A302 /* Transmission Help in Resources */,
    682688                                A2D0E0490A54A97C003C72CF /* Bandwidth.png in Resources */,
     689                                A2F6DB080A55F31C0058D1E5 /* SpeedLimitButtonPressed.tiff in Resources */,
     690                                A2F6DB090A55F31C0058D1E5 /* SpeedLimitButton.png in Resources */,
    683691                        );
    684692                        runOnlyForDeploymentPostprocessing = 0;
  • trunk/macosx/Controller.h

    r490 r491  
    5151   
    5252    IBOutlet NSMenuItem         * fAdvancedBarItem, * fSpeedLimitItem;
    53     IBOutlet NSButton           * fActionButton;
     53    IBOutlet NSButton           * fActionButton, * fSpeedLimitButton;
    5454   
    5555    IBOutlet SmoothAquaView     * fStatusBar;
  • trunk/macosx/Controller.m

    r490 r491  
    129129    BOOL speedLimit = [fDefaults boolForKey: @"SpeedLimit"];
    130130    [fSpeedLimitItem setState: speedLimit];
     131    if (speedLimit)
     132        [fSpeedLimitButton setState: NSOnState];
    131133   
    132134    [fActionButton setToolTip: @"Shortcuts for changing global settings."];
     135    [fSpeedLimitButton setToolTip: @"Speed Limit overrides the total bandwidth limits with its own limits."];
    133136
    134137    [fTableView setTorrents: fTorrents];
    135     [[fTableView tableColumnWithIdentifier: @"Torrent"] setDataCell:
    136         [[TorrentCell alloc] init]];
    137 
    138     [fTableView registerForDraggedTypes:
    139         [NSArray arrayWithObject: NSFilenamesPboardType]];
     138    [[fTableView tableColumnWithIdentifier: @"Torrent"] setDataCell: [[TorrentCell alloc] init]];
     139
     140    [fTableView registerForDraggedTypes: [NSArray arrayWithObject: NSFilenamesPboardType]];
    140141
    141142    //register for sleep notifications
     
    922923- (void) toggleSpeedLimit: (id) sender
    923924{
    924     BOOL enable = [fSpeedLimitItem state] == NSOffState;
    925 
    926     [fSpeedLimitItem setState: enable];
    927     [fDefaults setBool: enable forKey: @"SpeedLimit"];
    928 
    929     [fPrefsController enableSpeedLimit: enable];
     925    int state = [fSpeedLimitItem state] ? NSOffState : NSOnState;
     926
     927    [fSpeedLimitItem setState: state];
     928    [fSpeedLimitButton setState: state];
     929   
     930    [fPrefsController enableSpeedLimit: state];
    930931}
    931932
  • trunk/macosx/English.lproj/MainMenu.nib/classes.nib

    r490 r491  
    4747                fRatioSetItem = NSMenuItem;
    4848                fScrollView = NSScrollView;
     49                fSpeedLimitButton = NSButton;
    4950                fSpeedLimitItem = NSMenuItem;
    5051                fStateSortItem = NSMenuItem;
  • trunk/macosx/English.lproj/MainMenu.nib/info.nib

    r490 r491  
    3131        <array>
    3232                <integer>29</integer>
     33                <integer>21</integer>
    3334        </array>
    3435        <key>IBSystem Version</key>
  • trunk/macosx/English.lproj/PrefsWindow.nib/info.nib

    r490 r491  
    88        <dict>
    99                <key>153</key>
    10                 <string>302 469 548 217 0 0 1152 842 </string>
     10                <string>138 451 554 217 0 0 1152 842 </string>
    1111                <key>28</key>
    12                 <string>122 427 548 254 0 0 1152 842 </string>
     12                <string>197 449 554 254 0 0 1152 842 </string>
    1313                <key>41</key>
    14                 <string>130 394 548 297 0 0 1152 842 </string>
     14                <string>144 392 554 297 0 0 1152 842 </string>
    1515                <key>66</key>
    16                 <string>182 510 548 104 0 0 1152 842 </string>
     16                <string>241 503 554 104 0 0 1152 842 </string>
    1717        </dict>
    1818        <key>IBFramework Version</key>
Note: See TracChangeset for help on using the changeset viewer.