Re: [gpm] little chance in 50-no-critical-on-ac.patch (ubuntu)
- From: David Zeuthen <david fubar dk>
- To: Michaël Arnauts <michael arnauts gmail com>
- Cc: gnome-power-manager-list gnome org
- Subject: Re: [gpm] little chance in 50-no-critical-on-ac.patch (ubuntu)
- Date: Mon, 20 Feb 2006 16:35:27 -0500
On Mon, 2006-02-20 at 20:52 +0100, Micha�Arnauts wrote:
> This is what is in CVS:
> (in battery_status_changed_primary)
>
> if (warning_type == GPM_WARNING_ACTION) {
> gpm_tray_icon_notify (GPM_TRAY_ICON (manager->priv->tray_icon),
> 5000,
> _("Critical action"),
> NULL,
> _("The battery is below the critical level and "
> "this computer is about to shutdown."));
> /* wait 10 seconds for user-panic */
> g_usleep (1000 * 1000 * 10);
So you're block the the UI of g-p-m here? That's bad, isn't it?
Shouldn't you be using g_timeout_add() instead and have some kind of
state machine?
David
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]