Commit 3abb3e07 authored by Keith Packard's avatar Keith Packard
Browse files

kdrive: fix button emulation for iPAQ

parent 88810cfc
...@@ -1085,16 +1085,16 @@ KdCheckSpecialKeys(xEvent *xE) ...@@ -1085,16 +1085,16 @@ KdCheckSpecialKeys(xEvent *xE)
/* /*
* Check for buttons 1, 2 and 3 on the iPAQ * Check for buttons 1, 2 and 3 on the iPAQ
*/ */
if (sym == XK_Pointer_Button1) { if (sym == XK_Pointer_Button1 && kdMouseInfo) {
KdEnqueueMouseEvent(KD_MOUSE_DELTA | KD_BUTTON_1, 0, 0); KdEnqueueMouseEvent(kdMouseInfo, KD_MOUSE_DELTA | KD_BUTTON_1, 0, 0);
return; return;
} }
if (sym == XK_Pointer_Button2) { if (sym == XK_Pointer_Button2 && kdMouseInfo) {
KdEnqueueMouseEvent(KD_MOUSE_DELTA | KD_BUTTON_2, 0, 0); KdEnqueueMouseEvent(kdMouseInfo, KD_MOUSE_DELTA | KD_BUTTON_2, 0, 0);
return; return;
} }
if (sym == XK_Pointer_Button3) { if (sym == XK_Pointer_Button3 && kdMouseInfo) {
KdEnqueueMouseEvent(KD_MOUSE_DELTA | KD_BUTTON_3, 0, 0); KdEnqueueMouseEvent(kdMouseInfo, KD_MOUSE_DELTA | KD_BUTTON_3, 0, 0);
return; return;
} }
#endif #endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment