beep: use maximum loudness for error, otherwise system-default

This commit is contained in:
Leon Winter 2021-06-25 16:19:35 +02:00 committed by Albrecht Schlosser
parent 3dd8c314d6
commit 9d27ec8754

View File

@ -340,17 +340,19 @@ void Fl_X11_Screen_Driver::screen_dpi(float &h, float &v, int n)
void Fl_X11_Screen_Driver::beep(int type)
{
int vol;
switch (type) {
case FL_BEEP_DEFAULT :
case FL_BEEP_ERROR :
if (!fl_display) open_display();
XBell(fl_display, 0);
vol = 100;
break;
case FL_BEEP_DEFAULT :
default :
if (!fl_display) open_display();
XBell(fl_display, 50);
vol = 0;
break;
}
if (!fl_display) open_display();
XBell(fl_display, vol);
}