diff options
author | yokota <yokota@FreeBSD.org> | 1999-11-08 10:04:29 +0000 |
---|---|---|
committer | yokota <yokota@FreeBSD.org> | 1999-11-08 10:04:29 +0000 |
commit | 060ce4c0b57a9cb2b803afd8dc48d244f437168b (patch) | |
tree | 236b452028c99ea5f8cbf800d6f545b8186069d2 /sys/dev/syscons/scmouse.c | |
parent | e6b1d2277113d8872fff564760ea41c8a2c869bc (diff) | |
download | FreeBSD-src-060ce4c0b57a9cb2b803afd8dc48d244f437168b.zip FreeBSD-src-060ce4c0b57a9cb2b803afd8dc48d244f437168b.tar.gz |
- Added a new kernel configuration option: SC_TWOBUTTON_MOUSE.
The new option will make the right mouse button the `paste' button.
Useful for two button mice.
Submitted by: morganw@engr.sc.edu (Wes Morgan)
Diffstat (limited to 'sys/dev/syscons/scmouse.c')
-rw-r--r-- | sys/dev/syscons/scmouse.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/sys/dev/syscons/scmouse.c b/sys/dev/syscons/scmouse.c index bc4d93a..496cd7c 100644 --- a/sys/dev/syscons/scmouse.c +++ b/sys/dev/syscons/scmouse.c @@ -45,6 +45,14 @@ #include <dev/syscons/syscons.h> +#ifdef SC_TWOBUTTON_MOUSE +#define SC_MOUSE_PASTEBUTTON MOUSE_BUTTON3DOWN /* right button */ +#define SC_MOUSE_EXTENDBUTTON MOUSE_BUTTON2DOWN /* not really used */ +#else +#define SC_MOUSE_PASTEBUTTON MOUSE_BUTTON2DOWN /* middle button */ +#define SC_MOUSE_EXTENDBUTTON MOUSE_BUTTON3DOWN /* right button */ +#endif /* SC_TWOBUTTON_MOUSE */ + #define SC_WAKEUP_DELTA 20 /* for backward compatibility */ @@ -919,7 +927,7 @@ sc_mouse_ioctl(struct tty *tp, u_long cmd, caddr_t data, int flag, break; } break; - case MOUSE_BUTTON2DOWN: + case SC_MOUSE_PASTEBUTTON: switch (mouse->u.event.value) { case 0: /* up */ break; @@ -928,7 +936,7 @@ sc_mouse_ioctl(struct tty *tp, u_long cmd, caddr_t data, int flag, break; } break; - case MOUSE_BUTTON3DOWN: + case SC_MOUSE_EXTENDBUTTON: switch (mouse->u.event.value) { case 0: /* up */ if (!(cur_scp->mouse_buttons & MOUSE_BUTTON1DOWN)) |