Re: Programmatically showing the gnome panel logout dialog from external program



2006/5/16, Marek Habersack <grendel caudium net>:
On Tue, May 16, 2006 at 01:09:13AM +0100, Gustavo Carneiro scribbled:
[snip]
> >will do just that, but I  had another thought occur - I need to take
> >care of the desktops users left logged in in GNOME. Is there any mechanism
> >in GNOME to start a program after a certain period of idleness, or a
> >programmatic hook/signal which I can intercept in order to implement auto
> >logout for idle desktop sessions? I couldn't find anything of that kind in
> >the docs,
>
>
>  I know gajim has something to that effect, as most IM clients do.  It
> seems to use a XScreenSaver extension...
>
> http://trac.gajim.org/browser/trunk/src/common/idle.c
Thanks :) - I looked at similar code in GAIM, but was kinda expecting that
GNOME would have some sort of standard code for the applications to take
advantage of (such code would be quite useful, I think) - but doing it the
way you pointed out is just as fine. Thanks again,


The new Gnome Screensaver provides a DBus API that you can listen to.
I'm not currently up-to-date with the functionality it provides, but
it sends out messages when the screensaver activates and IIRC, there's
also a method to get the idle time.

xchat-gnome has a plug-in that uses this (autoaway) and so does gaim I think.

Autoaway for xchat-gnome is here:
   http://svn.navi.cx/misc/trunk/xchat-gnome/plugins/autoaway/

Regards,
Isak



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]