From: Jordan Lee Date: Mon, 21 Jan 2013 21:48:52 +0000 (+0000) Subject: (qt) #5239 'client should have the option to play a sound when the download completes... X-Git-Tag: 2.80~243 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2262c7c5651cd40c45d21aed9f1ae8c2b7d31e4d;p=transmission (qt) #5239 'client should have the option to play a sound when the download completes' -- use QApplication::beep() on OS X and Mac. Patch by rb07 --- diff --git a/qt/app.cc b/qt/app.cc index b8dd62d16..a4216706e 100644 --- a/qt/app.cc +++ b/qt/app.cc @@ -288,7 +288,13 @@ MyApp :: onTorrentCompleted( int id ) notify (tr("Torrent Completed"), tor->name()); if (myPrefs->getBool (Prefs::COMPLETE_SOUND_ENABLED)) - QProcess::execute (myPrefs->getString(Prefs::COMPLETE_SOUND_COMMAND)); + { +#if defined( Q_OS_WIN ) || defined( Q_OS_MAC ) + QApplication::beep(); +#else + QProcess::execute (myPrefs->getString(Prefs::COMPLETE_SOUND_COMMAND)); +#endif + } disconnect( tor, SIGNAL(torrentCompleted(int)), this, SLOT(onTorrentCompleted(int)) ); }