Use "Instant Message Notification" system sound on Windows, use gdk_beep() on Unix

Note: gdk_beep() is expected to be replaced with libcanberra stuff.
This commit is contained in:
Berke Viktor 2013-04-27 23:26:26 +02:00
parent 6001ceff9f
commit c6513ea7a2
1 changed files with 10 additions and 0 deletions

View File

@ -662,7 +662,17 @@ fe_beep (session *sess)
{
if (!prefs.hex_gui_focus_omitalerts || !fe_gui_info (sess, 0) == 1)
{
#ifdef WIN32
if (!PlaySound ("Notification.IM", NULL, SND_ALIAS|SND_ASYNC))
{
/* This is really just a fallback attempt, may or may not work on new Windows releases, especially on x64.
* You should set up the "Instant Message Notification" system sound instead, supported on Vista and up.
*/
Beep (1000, 50);
}
#else
gdk_beep ();
#endif
}
}