Preventing screensaver when playing movie?

Rui Tiago Cação Matos tiagomatos at gmail.com
Tue Feb 26 10:42:45 PST 2008


On 26/02/2008, Dotan Cohen <dotancohen at gmail.com> wrote:
> On 26/02/2008, Kevin DeKorte <kdekorte at gmail.com> wrote:
>  > On Tue, 2008-02-26 at 19:02 +0100, Erik wrote:
>  >  > Suppose that we have the following situation. A user has told the system
>  >  > to "turn off the display after N minutes of inactivity". Then he starts
>  >  > the media player, opens a file and presses a button called play. The
>  >  > media player interprets this as the user saying "play this movie, but do
>  >  > not turn off the display while playing it, because i will watch it even
>  >  > though I do not interact with the system".
>  >  >
>  >  > So the media player has to do something like this. Each time the
>  >  > application updates the display with a new animation frame, it marks
>  >  > that update with a special flag, indicating that this is the kind of
>  >  > thing that the user may be watching even though he has not interacted
>  >  > with the system
>  >  > for a while. System then resets the screensaver countdown. However it
>  >  > does not reset the session locking countdown, because only real input
>  >  > may do that, for security reasons. So the user may have to give his
>  >  > password when he wants to interact with the system after playing the movie.
>  >  >
>  >  > How can the media player achieve this with xorg?
>  >
>  >
>  > With gnome-mplayer, I use a dbus message to tell gnome-screensaver to be
>  >  inhibited while a video is being played.
>  >
>  >  CVS can be viewed here
>  >
>  >  http://dekorte.homeip.net/cgi-bin/cvsweb.cgi/gnome-mplayer/src/dbus-interface.c?rev=1.73
>  >
>  >  It is the last function on that page.
>  >
>  >  Kevin
>
>
> Any solution for KDE users who prefer mplayer?

$ man XScreenSaverSuspend

which mplayer uses if you install your distro's libXScrnSaver-devel
equivalent before compiling it.

I'm not sure this answers the original poster's question since I'm not
sure if this will prevent gnome-screensaver from locking the screen.

Rui



More information about the xorg mailing list