Skip to content

Commit

Permalink
input/atari: Fix mouse movement and button mapping
Browse files Browse the repository at this point in the history
Up and down movements were reversed, left and right buttons were swapped.

Signed-off-by: Geert Uytterhoeven <[email protected]>
  • Loading branch information
geertu committed May 19, 2011
1 parent 186f200 commit 659e6ed
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions drivers/input/mouse/atarimouse.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,15 @@ static void atamouse_interrupt(char *buf)
#endif

/* only relative events get here */
dx = buf[1];
dy = -buf[2];
dx = buf[1];
dy = buf[2];

input_report_rel(atamouse_dev, REL_X, dx);
input_report_rel(atamouse_dev, REL_Y, dy);

input_report_key(atamouse_dev, BTN_LEFT, buttons & 0x1);
input_report_key(atamouse_dev, BTN_LEFT, buttons & 0x4);
input_report_key(atamouse_dev, BTN_MIDDLE, buttons & 0x2);
input_report_key(atamouse_dev, BTN_RIGHT, buttons & 0x4);
input_report_key(atamouse_dev, BTN_RIGHT, buttons & 0x1);

input_sync(atamouse_dev);

Expand Down

0 comments on commit 659e6ed

Please sign in to comment.