Fix the Right-Shift on the LK501 keyboard in a different way. My previous

attempt results in the up and down arrows not repeating in the X server.
The keyboard division table is modified to place the Right-Shift keycode
into division 6 along with the Left-Shift and Control.  A corresponding
change to the X server lk201 keyboard handler is also required.
This commit is contained in:
mhitch 1998-11-13 01:59:51 +00:00
parent de234f5dda
commit 7b16048c5a
1 changed files with 15 additions and 5 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: dtop.c,v 1.34 1998/10/29 04:54:20 jonathan Exp $ */
/* $NetBSD: dtop.c,v 1.35 1998/11/13 01:59:51 mhitch Exp $ */
/*-
* Copyright (c) 1992, 1993
@ -94,7 +94,7 @@ SOFTWARE.
********************************************************/
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
__KERNEL_RCSID(0, "$NetBSD: dtop.c,v 1.34 1998/10/29 04:54:20 jonathan Exp $");
__KERNEL_RCSID(0, "$NetBSD: dtop.c,v 1.35 1998/11/13 01:59:51 mhitch Exp $");
#include "rasterconsole.h"
@ -191,14 +191,24 @@ void dtopstart __P((struct tty *));
* lk201 keyboard divisions and up/down mode key bitmap.
*/
#define NUMDIVS 14
static u_char divbeg[NUMDIVS] = {0xbf, 0x91, 0xbc, 0xbd, 0xb0, 0xad, 0xa6,
/*
* NOTE: the right shift key was included in division 8 with the up/down
* arrow keys for some odd reason. This causes a problem for
* the X11R5 server code, as it controls the key modes by divisions.
* The fix is to adjust the division table by changing the start
* of division 6 (which includes the shift and control keys) to
* include the right shift [0xab] and changing the end of division
* 8 to be the the up arrow [0xaa]. The initial key mode is also
* modified to include the right shift key as up/down.
*/
static u_char divbeg[NUMDIVS] = {0xbf, 0x91, 0xbc, 0xbd, 0xb0, 0xab, 0xa6,
0xa9, 0x88, 0x56, 0x63, 0x6f, 0x7b, 0x7e};
static u_char divend[NUMDIVS] = {0xff, 0xa5, 0xbc, 0xbe, 0xb2, 0xaf, 0xa8,
0xac, 0x90, 0x62, 0x6e, 0x7a, 0x7d, 0x87};
0xaa, 0x90, 0x62, 0x6e, 0x7a, 0x7d, 0x87};
/*
* Initial defaults, groups 5 and 6 are up/down
*/
static u_long keymodes[8] = {0, 0, 0, 0, 0, 0x0003e000, 0, 0};
static u_long keymodes[8] = {0, 0, 0, 0, 0, 0x0003e800, 0, 0};