diff --git a/macosx/Controller.m b/macosx/Controller.m index 5424927a7..7bf1240a9 100644 --- a/macosx/Controller.m +++ b/macosx/Controller.m @@ -1344,6 +1344,13 @@ static void sleepCallBack(void * controller, io_service_t y, natural_t messageTy [self applyFilter: nil]; [fInfoController updateInfoStatsAndSettings]; + if ([fDefaults boolForKey: @"PlaySeedingSound"]) + { + NSSound * sound; + if ((sound = [NSSound soundNamed: @"Submarine"])) + [sound play]; + } + [GrowlApplicationBridge notifyWithTitle: @"Seeding Complete" description: [[notification object] name] notificationName: GROWL_SEEDING_COMPLETE iconData: nil priority: 0 isSticky: NO clickContext: nil]; } diff --git a/macosx/Defaults.plist b/macosx/Defaults.plist index d958552d8..9fbf61f08 100644 --- a/macosx/Defaults.plist +++ b/macosx/Defaults.plist @@ -2,8 +2,6 @@ - - AutoImport AutoImportDirectory @@ -52,6 +50,8 @@ ~/Desktop PlayDownloadSound + PlaySeedingSound + RatioCheck RatioLimit diff --git a/macosx/English.lproj/PrefsWindow.nib/classes.nib b/macosx/English.lproj/PrefsWindow.nib/classes.nib index b01522eae..f0669aa7e 100644 --- a/macosx/English.lproj/PrefsWindow.nib/classes.nib +++ b/macosx/English.lproj/PrefsWindow.nib/classes.nib @@ -40,6 +40,7 @@ fImportFolderPopUp = NSPopUpButton; fNetworkView = NSView; fPlayDownloadSoundCheck = NSButton; + fPlaySeedingSoundCheck = NSButton; fPortField = NSTextField; fQuitCheck = NSButton; fQuitDownloadingCheck = NSButton; diff --git a/macosx/English.lproj/PrefsWindow.nib/info.nib b/macosx/English.lproj/PrefsWindow.nib/info.nib index c4fe712c7..aeea74e3a 100644 --- a/macosx/English.lproj/PrefsWindow.nib/info.nib +++ b/macosx/English.lproj/PrefsWindow.nib/info.nib @@ -11,7 +11,7 @@ 28 139 281 538 290 0 0 1152 842 41 - 161 333 584 355 0 0 1152 842 + 115 371 538 378 0 0 1152 842 66 353 613 538 104 0 0 1152 842 diff --git a/macosx/English.lproj/PrefsWindow.nib/keyedobjects.nib b/macosx/English.lproj/PrefsWindow.nib/keyedobjects.nib index 2b5b59ea2..28c52649c 100644 Binary files a/macosx/English.lproj/PrefsWindow.nib/keyedobjects.nib and b/macosx/English.lproj/PrefsWindow.nib/keyedobjects.nib differ diff --git a/macosx/PrefsController.h b/macosx/PrefsController.h index e4f080c00..bba14d186 100644 --- a/macosx/PrefsController.h +++ b/macosx/PrefsController.h @@ -37,7 +37,7 @@ IBOutlet NSButton * fQuitCheck, * fRemoveCheck, * fQuitDownloadingCheck, * fRemoveDownloadingCheck, * fBadgeDownloadRateCheck, * fBadgeUploadRateCheck, - * fPlayDownloadSoundCheck, + * fPlayDownloadSoundCheck, * fPlaySeedingSoundCheck, * fCopyTorrentCheck, * fDeleteOriginalTorrentCheck, * fAutoImportCheck, * fAutoSizeCheck; diff --git a/macosx/PrefsController.m b/macosx/PrefsController.m index c41189c36..f275120d4 100644 --- a/macosx/PrefsController.m +++ b/macosx/PrefsController.m @@ -193,6 +193,7 @@ //set play sound [fPlayDownloadSoundCheck setState: [fDefaults boolForKey: @"PlayDownloadSound"]]; + [fPlaySeedingSoundCheck setState: [fDefaults boolForKey: @"PlaySeedingSound"]]; //set start setting NSString * startSetting = [fDefaults stringForKey: @"StartSetting"]; @@ -515,7 +516,11 @@ - (void) setPlaySound: (id) sender { - [fDefaults setBool: [sender state] forKey: @"PlayDownloadSound"]; + if (sender == fPlayDownloadSoundCheck) + [fDefaults setBool: [sender state] forKey: @"PlayDownloadSound"]; + else if (sender == fPlaySeedingSoundCheck) + [fDefaults setBool: [sender state] forKey: @"PlaySeedingSound"]; + else; } - (void) setUpdate: (id) sender