Changeset 733


Ignore:
Timestamp:
Aug 7, 2006, 12:46:47 AM (17 years ago)
Author:
livings124
Message:

Option to play sound when downloads finish (for now the sound is "Glass").

Location:
trunk/macosx
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/Controller.m

    r732 r733  
    897897    [self applyFilter: nil];
    898898    [self checkToStartWaiting: torrent];
     899
     900    if ([fDefaults boolForKey: @"PlayDownloadSound"])
     901    {
     902        NSSound * sound;
     903        if ((sound = [NSSound soundNamed: @"Glass"]))
     904            [sound play];
     905    }
    899906
    900907    [GrowlApplicationBridge notifyWithTitle: @"Download Complete" description: [torrent name]
  • trunk/macosx/Defaults.plist

    r695 r733  
    5151        <key>MoveFolder</key>
    5252        <string>~/Desktop</string>
     53        <key>PlayDownloadSound</key>
     54        <true/>
    5355        <key>RatioCheck</key>
    5456        <false/>
  • trunk/macosx/English.lproj/PrefsWindow.nib/classes.nib

    r725 r733  
    1414                setLimitCheck = id;
    1515                setMoveTorrent = id;
     16                setPlaySound = id;
    1617                setPort = id;
    1718                setRatio = id;
     
    3940                fImportFolderPopUp = NSPopUpButton;
    4041                fNetworkView = NSView;
     42                fPlayDownloadSoundCheck = NSButton;
    4143                fPortField = NSTextField;
    4244                fQuitCheck = NSButton;
  • trunk/macosx/English.lproj/PrefsWindow.nib/info.nib

    r725 r733  
    1010                <string>155 441 554 217 0 0 1152 842 </string>
    1111                <key>28</key>
    12                 <string>229 409 554 290 0 0 1152 842 </string>
     12                <string>139 281 538 290 0 0 1152 842 </string>
    1313                <key>41</key>
    14                 <string>125 133 554 321 0 0 1152 842 </string>
     14                <string>161 333 584 355 0 0 1152 842 </string>
    1515                <key>66</key>
    1616                <string>353 613 538 104 0 0 1152 842 </string>
     
    1818        <key>IBFramework Version</key>
    1919        <string>446.1</string>
     20        <key>IBOpenObjects</key>
     21        <array>
     22                <integer>41</integer>
     23        </array>
    2024        <key>IBSystem Version</key>
    2125        <string>8J135</string>
  • trunk/macosx/PrefsController.h

    r712 r733  
    3838                            * fQuitDownloadingCheck, * fRemoveDownloadingCheck,
    3939                            * fBadgeDownloadRateCheck, * fBadgeUploadRateCheck,
     40                            * fPlayDownloadSoundCheck,
    4041                            * fCopyTorrentCheck, * fDeleteOriginalTorrentCheck,
    4142                            * fAutoImportCheck, * fAutoSizeCheck;
     
    6566- (void) setShowMessage:    (id) sender;
    6667- (void) setBadge:          (id) sender;
     68- (void) setPlaySound:      (id) sender;
    6769- (void) setUpdate:         (id) sender;
    6870- (void) checkUpdate;
  • trunk/macosx/PrefsController.m

    r720 r733  
    192192    [fBadgeUploadRateCheck setState: [fDefaults boolForKey: @"BadgeUploadRate"]];
    193193   
     194    //set play sound
     195    [fPlayDownloadSoundCheck setState: [fDefaults boolForKey: @"PlayDownloadSound"]];
     196   
    194197    //set start setting
    195198    NSString * startSetting = [fDefaults stringForKey: @"StartSetting"];
     
    511514}
    512515
     516- (void) setPlaySound: (id) sender
     517{
     518    [fDefaults setBool: [sender state] forKey: @"PlayDownloadSound"];
     519}
     520
    513521- (void) setUpdate: (id) sender
    514522{
Note: See TracChangeset for help on using the changeset viewer.