[MPlayer-dev-eng] [PATCH] Use XScreenSaverSuspend if supported

Adam Tlałka atlka at pg.gda.pl
Thu Dec 20 17:16:26 CET 2007


Dnia 20-12-2007, Cz o godzinie 16:45 +0100, Reimar Döffinger pisze:
> Hello,
> On Thu, Dec 20, 2007 at 03:58:18PM +0100, Adam Tlałka wrote:
> > Dnia 20-12-2007, Cz o godzinie 14:22 +0100, Reimar Döffinger pisze:
> > > I also added a QueryExtension because the documentation says without it
> > > the effects of the functions are undefined.
> > > I advise you to not ignore this, because I intend to apply soon and then
> > > the KDE-specific hack _will_ be removed unless you have exceptionally
> > > good reasons not to ("KDE does not support disabling via
> > > XScreenSaverSuspend" does not count).
> > 
> > A simpler method is usage of periodical call of XResetScreenSaver
> > function which does not need special X-server extension.
> 
> Yes, but these periodical calls are a bit ugly. But yes, replacing
> xscreensaver_heartbeat for old X versions by this is a possible next step.
> 

Yes, this is what I mean.

> > It resets internal X-server counters so if KDE screensaver can see them
> > it should work out of the box. Also DPMI and blanking will be disabled
> > in case of not using any screensaver program so there is no need for
> > special DPMI handling code in mplayer.
> 
> Should be the same with XScreenSaverSuspend except that it does not need
> to be called periodically.
> 

Only difference is that we do not need use X-server extensions. But to
function properly with different screensavers X-server must support Xss
extension so they could read internal X-server idle counters or register
itself to get message from X-server. So XScreenSaverSuspend only
simplify mplayer code side so it can live without using Xss.

> > gnome-screensaver program should be patched to monitor internal X-server
> > counters so this method could be used.
> 
> There seems to be some resistance to this from what I heard since
> reportedly the X developers themselves are not really "pushing" these
> extensions either...

I don't know what they really want to implement but I can try to make a
patch to gnome-screensaver  and send it to gnome people. There is a
patch needed to xscreensaver too so it could be the example of proper
problem solution ;).

Regards
-- 
Adam Tlałka       mailto:atlka at pg.gda.pl    ^v^ ^v^ ^v^
System  & Network Administration Group       - - - ~~~~~~
Computer Center, Gdańsk University of Technology, Poland
PGP public key:   finger atlka at sunrise.pg.gda.pl





More information about the MPlayer-dev-eng mailing list