From d370e689f23079bf278d995584456aaeb89acd44 Mon Sep 17 00:00:00 2001 From: Deron Johnson Date: Thu, 17 Feb 2005 22:44:41 +0000 Subject: Joined with branch XORG-6_8_2. --- src/kbd.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/src/kbd.c b/src/kbd.c index f611a66..8e8dfbc 100644 --- a/src/kbd.c +++ b/src/kbd.c @@ -1,4 +1,4 @@ -/* $XdotOrg: xc/programs/Xserver/hw/xfree86/input/keyboard/kbd.c,v 1.5 2004/08/29 21:06:00 kem Exp $ */ +/* $XdotOrg: xc/programs/Xserver/hw/xfree86/input/keyboard/kbd.c,v 1.6.2.1 2004/12/16 03:38:45 gisburn Exp $ */ /* $XFree86: xc/programs/Xserver/hw/xfree86/input/keyboard/kbd.c,v 1.8 2003/11/03 05:11:47 tsi Exp $ */ /* @@ -12,7 +12,7 @@ * xf86Events.c and xf86Io.c which are * Copyright 1990,91 by Thomas Roell, Dinkelscherben, Germany. */ -/* $XdotOrg: xc/programs/Xserver/hw/xfree86/input/keyboard/kbd.c,v 1.5 2004/08/29 21:06:00 kem Exp $ */ +/* $XdotOrg: xc/programs/Xserver/hw/xfree86/input/keyboard/kbd.c,v 1.6.2.1 2004/12/16 03:38:45 gisburn Exp $ */ #define NEED_EVENTS #include "X.h" @@ -135,7 +135,7 @@ static const char *kbdDefaults[] = { "Protocol", "standard", "AutoRepeat", "500 30", "XkbRules", __XKBDEFRULES__, - "XkbModel", "pc101", + "XkbModel", "pc105", "XkbLayout", "us", "Panix106", "off", "CustomKeycodes", "off", @@ -372,6 +372,7 @@ KbdCtrl( DeviceIntPtr device, KeybdCtrl *ctrl) } #endif pKbd->SetLeds(pInfo, pKbd->leds); + pKbd->autoRepeat = ctrl->autoRepeat; return (Success); } @@ -720,14 +721,14 @@ PostKbdEvent(InputInfoPtr pInfo, unsigned int scanCode, Bool down) /* * check for an autorepeat-event */ - if (down) { + if (down && KeyPressed(keycode)) { int num = keycode >> 3; int bit = 1 << (keycode & 7); - if ((keyc->down[num] & bit) && - ((kbdfeed->ctrl.autoRepeat != AutoRepeatModeOn) || - keyc->modifierMap[keycode] || - !(kbdfeed->ctrl.autoRepeats[num] & bit))) - return; + + if ((pKbd->autoRepeat != AutoRepeatModeOn) || + keyc->modifierMap[keycode] || + !(kbdfeed->ctrl.autoRepeats[num] & bit)) + return; } if (UsePrefix) { -- cgit v1.2.1