[mythtv] screensaver patch

Matt Zimmerman mdz at debian.org
Wed Feb 25 15:24:56 EST 2004


On Mon, Dec 22, 2003 at 02:09:04PM -0800, Cliff Draper wrote:

> I'm attaching the patch for automatic disabling of screensavers
> (standard X blanking, DPMS, and xscreensaver).  It adds the following
> functions to util.cpp:
>   void ScreenSaverOff();
>   void ScreenSaverRestore();
>   void ResetScreenSaver();
> 
> which are called at the right locations when the video player makes a
> state transition, when pause is engaged or disengaged, and when
> myth_system is called.

I applied a simpler version of this, using MythContext rather than static
storage and global functions, without all the #ifdefs and only handling the
built-in X screensaver.

To use DPMS, you'll have to figure out what's wrong with using the header;
I'd rather not duplicate those declarations in the code.

For xscreensaver, there should be configuration options for that stuff
rather than preprocessor macros.  Ideally, rather than running an external
program, it would run a thread to write the wakeup messages.  It definitely
shouldn't create hardcoded files insecurely in /tmp.

-- 
 - mdz


More information about the mythtv-dev mailing list