GNU bug report logs -
#63620
30.0.50; [Feature Request] run hooks on sleep/wake
Previous Next
Full log
View this message in rfc822 format
Andrew Cohen <acohen <at> ust.hk> writes:
Hi Andrew,
> MA> Another idea: There are the properties Docked, LidClosed and
> MA> OnExternalPower. Perhaps you could check them in your
> MA> sleep-handler, and start different actions depending on their
> MA> value.
>
> That is a good idea. We could generalize the mode to handle a variety of
> things other than sleep. Maybe we should use a new event category
> (<system-event> or something) rather than sleep-event. This general
> event can contain actions for sleep, docked, lidclosed, etc. And we
> provide a mode for system-event, with sleep just one of the actions. For
> D-Bus, this becomes pretty trivial---we just inject all the events we
> are interested into system-event and have an appropriate handler.
Yes, that's more or less the direction I was thinking of. I'm just
polishing my patch, will push it later today. I still keep the event
name sleep-event; we can change it later to system-event. But it should
be sufficient for now, for your tests and proposed patches for review.
What I'll appreciate is, if you could write down what system-event would
be good for, and which attributes a (system-event ...) event shall
carry. However, this is rather a discussion for the emecs-devel <at> gnu.org
ML, in order to get more attention from the Emacs developers.
> I must say, I hadn't fully appreciated all that can be done with
> D-Bus.
😊
> Best,
> Andy
Best regards, Michael.
This bug report was last modified 130 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.