Both for the hearing impaired and for people who like
to use visible bells rather than bother their roommates
with late-night programming, DrJava should support a
visible bell or minimally the ability to turn OFF the
Toolkit beep()'s. This could go in the configuration
box which I think is under development...
Logged In: YES
user_id=435960
Now that Theo has explained the configuration-specific
methods, I think this could be done by adding a
boolean _visualBellOn;
and having a configuration-style method:
setVisualBell(boolean b);
set from the lowest layer in the cascading configuration
files.
Then, create a method void visualBell(); in the GUI to flash
some subset of the screen -- experiment to find out what
works best as a more traditional 'visual bell.' Each place
in the code that calls toolkit.beep() should then be
replaced by:
if (_visualBellOn)
gui.visualBell();
else
toolkit.beep();
If anyone has any thoughts on how this layout could be
improved, please let me know. Here's the user story:
I'm up late working on my 421 project but my roommate is
trying to sleep and is getting mad at all the beeping noises
my computer is making when I get alerts, etc. I alter my
configuration (whether through GUI or a text-editor on a
user config file) such that VisualBell=On, and upon
re-opening DrJava, no more noises are emitted, but instead
part of the screen flashes to let me know that DrJava needs
my attention nonetheless.
Logged In: YES
user_id=435960
Of course, a better idea would be to place a beep() method
in the model which contained that if statement...i also
didn't mean to put this on pending.