Ignore:
Timestamp:
2019-05-18T06:42:01Z (5 years ago)
Author:
Matthieu Riolo <matthieu.riolo@…>
Children:
a8171b86
Parents:
95f603c
git-author:
Matthieu Riolo <matthieu.riolo@…> (2019-05-16 09:46:12)
git-committer:
Matthieu Riolo <matthieu.riolo@…> (2019-05-18 06:42:01)
Message:

Keyboard layouts can now identify itself

The structure layout_ops_t has been extended with the
parameter get_name() which returns the name of the kb layout

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/hid/input/layout/us_qwerty.c

    r95f603c rf9edc7b  
    4848static void us_qwerty_destroy(layout_t *);
    4949static wchar_t us_qwerty_parse_ev(layout_t *, kbd_event_t *ev);
     50static const char *us_qwerty_name(void);
    5051
    5152static const layout_ops_t layout_intern = {
    5253        .create = us_qwerty_create,
    5354        .destroy = us_qwerty_destroy,
    54         .parse_ev = us_qwerty_parse_ev
     55        .parse_ev = us_qwerty_parse_ev,
     56        .get_name = us_qwerty_name
    5557};
    5658
     
    6567layout_ops_t layout_active = layout_intern;
    6668#endif
     69
     70
     71static const char *us_qwerty_name(void)
     72{
     73        return "us_qwerty";
     74}
    6775
    6876static wchar_t map_lcase[] = {
Note: See TracChangeset for help on using the changeset viewer.