GNOME Bugzilla – Bug 345595
if suspend because the laptop lid is closed is cancelled due to file copy, beep to get the user's attention
Last modified: 2006-06-23 17:46:25 UTC
The enhancement in bug 334806 is excellent, and the bubble is a good idea, but if the laptop lid is closed, thus causing a suspend which is then cancelled because of file copying activity, there is no way for the user to know. I would suggest that the laptop beeps to get the user to open the lid again and see the bubble, rather than just popping up a bubble that the user will not see. Other information: I have not actually played with these bits (yet); this suggestion was the result of chatting with davidz on IRC about the kinds of things I will eventually be needing to test. So if something has already been done to address this possible issue, please feel free to close this!
Sounds sane. How do we beep? gstreamer playing a wav file seems overkill.
This seems to work well: GdkDisplay *display = gdk_display_get_default (); gdk_display_beep (display); Richard.
Committed to CVS HEAD: 2006-06-21 Richard Hughes <richard@hughsie.com> * src/gpm-common.c: * src/gpm-common.h: Add gpm_warning_beep () to allow us to make a sound when an important event has occurred. * src/gpm-manager.c: (gpm_manager_is_inhibit_valid): Beep if we stopped the action due to an inhibit to warn the user. Also beep if we are low on power for primary, UPS or mouse as these are important. This fixes bug #345595 If you are playing with the inhibit stuff, grab the rpms from my repo (FC5 only), and then use the gnome-power-inhibit-test program -- you can have as many instances as you like. Please re-open if this doesn't work for you. Richard.
One additional thing I just thought of. Some people _hate_ beeping. Is there a way to tell it to not beep, and flash or something instead? We'd want to warn that they would therefore not know of the suspend cancellation in the particular case of a lid being closed, but it really ought to be able to be turned off. (have not yet had a chance to test this. But thanks for the amazingly fast turn around!)
Committed to CVS HEAD: 2006-06-23 Richard Hughes <richard@hughsie.com> * data/gnome-power-manager.schemas.in: * src/gpm-manager.c: * src/gpm-prefs.h: In hindsight, not everyone likes beeping as commented on in #345595. Add a gconf variable /apps/gnome-power-manager/enable_pcskr_beeping to enable the user or distro to turn this off and on. Default on. Flashing a screen isn't a great idea for all those epileptics out there... I think a beep is best as thats the best we can do with the screen down and the power on.
Flashing a potential bad thing: true. Although, if we're giving a choice to people to turn it off, why not a choice to flash instead? Either way, though, letting people turn it off is excellent.