From fd084b5d28189727f1dff6022d2b421d772bcc1a Mon Sep 17 00:00:00 2001 From: runge Date: Mon, 10 Aug 2009 17:56:10 -0400 Subject: Improvements to -unixpw_cmd and -unixpw_nis. Experimental X11VNC_WATCH_DX_DY=1 for buggy theme menus, see: http://ubuntuforums.org/showthread.php?t=1223490 --- x11vnc/pointer.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'x11vnc/pointer.c') diff --git a/x11vnc/pointer.c b/x11vnc/pointer.c index 0a3d806..70d2b8e 100644 --- a/x11vnc/pointer.c +++ b/x11vnc/pointer.c @@ -343,11 +343,22 @@ void update_x11_pointer_position(int x, int y) { return; #else int rc; + static int watch_dx_dy = -1; RAWFB_RET_VOID + if (watch_dx_dy == -1) { + if (getenv("X11VNC_WATCH_DX_DY")) { + watch_dx_dy = 1; + } else { + watch_dx_dy = 0; + } + } + X_LOCK; - if (use_xwarppointer) { + if (watch_dx_dy && cursor_x == x && cursor_y == y) { + ; + } else if (use_xwarppointer) { /* * off_x and off_y not needed with XWarpPointer since * window is used: -- cgit v1.2.1