[Mplayer-cvslog] CVS: main/libvo x11_common.c,1.165,1.166

Tobias Diedrich CVS syncmail at mplayerhq.hu
Thu Feb 26 21:42:55 CET 2004


CVS change done by Tobias Diedrich CVS

Update of /cvsroot/mplayer/main/libvo
In directory mail:/var2/tmp/cvs-serv17641/libvo

Modified Files:
	x11_common.c 
Log Message:
Use system clock for xscreensaver pings

Index: x11_common.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/x11_common.c,v
retrieving revision 1.165
retrieving revision 1.166
diff -u -r1.165 -r1.166
--- x11_common.c	24 Feb 2004 21:09:21 -0000	1.165
+++ x11_common.c	26 Feb 2004 20:42:53 -0000	1.166
@@ -19,6 +19,7 @@
 #include "aspect.h"
 #include "geometry.h"
 #include "help_mp.h"
+#include "../osdep/timer.h"
 
 #include <X11/Xmd.h>
 #include <X11/Xlib.h>
@@ -1146,14 +1147,15 @@
 static Atom deactivate;
 static Atom screensaver;
 
-static float time_last;
+static unsigned int time_last;
 
-void xscreensaver_heartbeat(float time)
+void xscreensaver_heartbeat(void)
 {
+    unsigned int time = GetTimerMS();
     XEvent ev;
 
     if (mDisplay && xs_windowid &&
-	((time - time_last)>30 ||
+	((time - time_last)>30000 ||
 	 (time - time_last)<0)) {
 	time_last = time;
 




More information about the MPlayer-cvslog mailing list