mouse movement on VNC and MS Windows 2k

Adon adon "at" eecs.harvard.edu
Thu, 16 Nov 2000 05:21:13 +0000


i figured i'd try to fix this problem myself and have a short patch to
Xvnc.

in rfbserver.c,
add variables:
    static CARD16 oldx = 0, oldy = 0;
    static CARD8 oldmask = 0;

and add an if block around PtrAddEvent:
    if(msg.pe.x != oldx  
       || msg.pe.y != oldy
       || msg.pe.buttonMask != oldmask) {
        oldx = msg.pe.x;
        oldy = msg.pe.y;
        oldmask = msg.pe.buttonMask;
    
        PtrAddEvent(msg.pe.buttonMask,
            Swap16IfLE(msg.pe.x), Swap16IfLE(msg.pe.y), cl);
    }

that's it!

enjoy,
adon

-----Original Message----- 
From: Adon [mailto:adon "at" eecs.harvard.edu] 
Sent: den 11 oktober 2000 15:49 
To: vnc-list "at" uk.research.att.com 
Subject: mouse focus on unix server and windows 2000 client 

i have vnc server 3.3.3 running on freebsd and client 3.3.3 r2 running on 
windows 2000. i often use my window manager's (fvwm) keyboard shortcuts 
to move the mouse pointer since i hate to physically use the mouse due to 
repetitive stress injury concerns. with windows 2000, i no longer can do 
that because the mouse pointer moves back to where the physical mouse is 
located. in other words, if i move the cursor in the window manager, the 
cursor moves back, after about a second delay, to where the vnc mouse 
cursor (the dot) is located. 


i wonder if this behavior is an artifact of windows or vnc and if i can 
keep the server and client from synchronizing the mouse position if 
possible. even better, if the client synchronizes the mouse from the 
server, that would be great. 


thanks in advance, 
adon 
---------------------------------------------------------------------
To unsubscribe, send a message with the line: unsubscribe vnc-list
to majordomo "at" uk.research.att.com
See also: http://www.uk.research.att.com/vnc/intouch.html
---------------------------------------------------------------------