Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/hid/input/ctl/stty.c

    r60e5a856 rdcbb3ec  
    3333/**
    3434 * @file
    35  * @brief       Serial TTY-like keyboard controller driver.
     35 * @brief Serial TTY-like keyboard controller driver.
     36 *
     37 * Keyboard emulation on a serial terminal.
    3638 */
    3739
     
    4345#include <stroke.h>
    4446
    45 static void stty_ctl_parse_scancode(int);
     47static void stty_ctl_parse(sysarg_t);
    4648static int stty_ctl_init(kbd_dev_t *);
    47 static void stty_ctl_set_ind(kbd_dev_t *, unsigned);
     49static void stty_ctl_set_ind(kbd_dev_t *, unsigned int);
    4850
    4951kbd_ctl_ops_t stty_ctl = {
    50         .parse_scancode = stty_ctl_parse_scancode,
     52        .parse = stty_ctl_parse,
    5153        .init = stty_ctl_init,
    5254        .set_ind = stty_ctl_set_ind
     
    6365#include <stdio.h>
    6466
     67/**
     68 * Sequnece definitions are primarily for Xterm. Additionally we define
     69 * sequences that are unique to Gnome terminal -- most are the same but
     70 * some differ.
     71 */
    6572static int seq_defs[] = {
    6673        /* Not shifted */
     
    8188        0,      KC_MINUS,       0x2d, GSP_END,
    8289        0,      KC_EQUALS,      0x3d, GSP_END,
     90
    8391        0,      KC_BACKSPACE,   0x08, GSP_END,
    8492
     
    216224        0,      KC_RIGHT,       0x1b, 0x5b, 0x43, GSP_END,
    217225
     226        /*
     227         * Sequences specific to Gnome terminal
     228         */
     229        0,      KC_BACKSPACE,   0x7f, GSP_END, /* ASCII DEL */
     230        0,      KC_HOME,        0x1b, 0x4f, 0x48, GSP_END,
     231        0,      KC_END,         0x1b, 0x4f, 0x46, GSP_END,
     232
    218233        0,      0
    219234};
     
    228243}
    229244
    230 static void stty_ctl_parse_scancode(int scancode)
     245static void stty_ctl_parse(sysarg_t scancode)
    231246{
    232247        unsigned mods, key;
Note: See TracChangeset for help on using the changeset viewer.