In my previous post I told that I was experiencing about 50ms latency for left and right mouse clics. After some investigations I discovered that the problem was located in xorg.
It appears it’s not a bug, it’s a functionality called “3rd button emulation” that is useful with a 2 button mouse. Xorg waits up to 50ms to see if both left and right buttons are pressed, and in case it is, it generates a middle button press.
It’s nothing to say that this implementation is lame and should be disabled by default.
Following bug reports were filled by people complaining about that behavior:
Although a real middle button press is enough to disable the functionality (not persistent), it’s possible to disable it by default (works for Ubuntu 10.10):
sudo gedit /usr/share/X11/xorg.conf.d/20-mouse.conf
Copy-paste to following lines:
Option “Emulate3Buttons” “false”
Save, and Restart!report