Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/wscons Make auto repeat of events a compile time opt...



details:   https://anonhg.NetBSD.org/src/rev/bc09744b56cb
branches:  trunk
changeset: 580685:bc09744b56cb
user:      augustss <augustss%NetBSD.org@localhost>
date:      Wed May 04 01:52:16 2005 +0000

description:
Make auto repeat of events a compile time option, and have it off by default.
Turn on by WSKBD_EVENT_AUTOREPEAT.

diffstat:

 sys/dev/wscons/files.wscons |  3 ++-
 sys/dev/wscons/wskbd.c      |  8 ++++++--
 2 files changed, 8 insertions(+), 3 deletions(-)

diffs (63 lines):

diff -r b44576f5fb40 -r bc09744b56cb sys/dev/wscons/files.wscons
--- a/sys/dev/wscons/files.wscons       Tue May 03 22:58:14 2005 +0000
+++ b/sys/dev/wscons/files.wscons       Wed May 04 01:52:16 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: files.wscons,v 1.33 2004/07/29 22:29:37 jmmv Exp $
+# $NetBSD: files.wscons,v 1.34 2005/05/04 01:52:16 augustss Exp $
 
 #
 # "Workstation Console" glue; attaches frame buffer to emulator & keyboard,
@@ -31,6 +31,7 @@
                                WSCONS_SUPPORT_PCVTFONTS
                                WSCONS_SUPPORT_ISO7FONTS
                                WSDISPLAY_SCROLLSUPPORT
+                               WSKBD_EVENT_AUTOREPEAT
 defparam opt_wsdisplay_compat.h        WSCOMPAT_USL_SYNCTIMEOUT
                                WSDISPLAY_DEFAULTSCREENS
 
diff -r b44576f5fb40 -r bc09744b56cb sys/dev/wscons/wskbd.c
--- a/sys/dev/wscons/wskbd.c    Tue May 03 22:58:14 2005 +0000
+++ b/sys/dev/wscons/wskbd.c    Wed May 04 01:52:16 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: wskbd.c,v 1.79 2005/05/03 13:13:07 augustss Exp $ */
+/* $NetBSD: wskbd.c,v 1.80 2005/05/04 01:52:16 augustss Exp $ */
 
 /*
  * Copyright (c) 1996, 1997 Christopher G. Demetriou.  All rights reserved.
@@ -79,7 +79,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: wskbd.c,v 1.79 2005/05/03 13:13:07 augustss Exp $");
+__KERNEL_RCSID(0, "$NetBSD: wskbd.c,v 1.80 2005/05/04 01:52:16 augustss Exp $");
 
 #include "opt_ddb.h"
 #include "opt_kgdb.h"
@@ -521,9 +521,11 @@
                                                   sc->id->t_symbols[i]);
                }
        } else {
+#if defined(WSKBD_EVENT_AUTOREPEAT)
                /* queue event */
                wskbd_deliver_event(sc, sc->sc_repeat_type,
                                    sc->sc_repeat_value);
+#endif /* defined(WSKBD_EVENT_AUTOREPEAT) */
        }
        callout_reset(&sc->sc_repeat_ch,
            (hz * sc->sc_keyrepeat_data.delN) / 1000, wskbd_repeat, sc);
@@ -640,6 +642,7 @@
 
        wskbd_deliver_event(sc, type, value);
 
+#if defined(WSKBD_EVENT_AUTOREPEAT)
        /* Repeat key presses if set. */
        if (type == WSCONS_EVENT_KEY_DOWN && sc->sc_keyrepeat_data.del1 != 0) {
                sc->sc_repeat_type = type;
@@ -649,6 +652,7 @@
                    (hz * sc->sc_keyrepeat_data.del1) / 1000,
                    wskbd_repeat, sc);
        }
+#endif /* defined(WSKBD_EVENT_AUTOREPEAT) */
 }
 
 /*



Home | Main Index | Thread Index | Old Index