Add middle-click with 'p' master
authorJoshua Wise <joshua@laminarflow.(none)>
Fri, 20 Jun 2008 19:16:39 +0000 (15:16 -0400)
committerJoshua Wise <joshua@laminarflow.(none)>
Fri, 20 Jun 2008 19:16:39 +0000 (15:16 -0400)
xvmouse.c

index 44e94d9..0d83eb6 100644 (file)
--- a/xvmouse.c
+++ b/xvmouse.c
@@ -24,7 +24,7 @@ unsigned long long now()
        return tv.tv_sec*1000000 + tv.tv_usec;
 }
 
-void main()
+int main()
 {
        int e;
        XEvent ev;
@@ -80,6 +80,8 @@ void main()
                                        XTestFakeButtonEvent(dpy, 1, ev.type == KeyPress, 0);
                                else if (!strcmp(keystr, "o"))
                                        XTestFakeButtonEvent(dpy, 3, ev.type == KeyPress, 0);
+                               else if (!strcmp(keystr, "p"))
+                                       XTestFakeButtonEvent(dpy, 2, ev.type == KeyPress, 0);
                                else if (!strcmp(keystr, "apostrophe") || !strcmp(keystr, "semicolon")) {
                                        if (ev.type == KeyPress)
                                                status |= STATUS_TAPJUMP;
@@ -153,6 +155,5 @@ void main()
                        XTestFakeRelativeMotionEvent(dpy, 0, 2, 0);
        }
        
-       
        exit(0);
-}
\ No newline at end of file
+}
This page took 0.272772 seconds and 4 git commands to generate.