Changeset 215abc1 in mainline for uspace/srv/kbd/layout/cz.c


Ignore:
Timestamp:
2009-06-03T18:49:33Z (16 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
05b9912
Parents:
bbdbf86
Message:

keyboard server rewrite: rename "kbd events" to more generic "console events" and similar changes
rename key_buffer.* to keybuffer.*
coding style changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/kbd/layout/cz.c

    rbbdbf86 r215abc1  
    2828
    2929/** @addtogroup kbd
    30  * @brief       US QWERTY leyout.
     30 * @brief US QWERTY leyout.
    3131 * @{
    32  */ 
     32 */
    3333
    3434#include <kbd.h>
    35 #include <kbd/kbd.h>
    36 #include <kbd/keycode.h>
     35#include <io/console.h>
     36#include <io/keycode.h>
    3737#include <bool.h>
    3838#include <layout.h>
    3939
    4040static void layout_reset(void);
    41 static wchar_t layout_parse_ev(kbd_event_t *ev);
     41static wchar_t layout_parse_ev(console_event_t *ev);
    4242
    4343enum m_state {
    4444        ms_start,
    4545        ms_hacek,
    46         ms_carka       
     46        ms_carka
    4747};
    4848
     
    273273}
    274274
    275 static wchar_t parse_ms_hacek(kbd_event_t *ev)
     275static wchar_t parse_ms_hacek(console_event_t *ev)
    276276{
    277277        wchar_t c;
     
    291291}
    292292
    293 static wchar_t parse_ms_carka(kbd_event_t *ev)
     293static wchar_t parse_ms_carka(console_event_t *ev)
    294294{
    295295        wchar_t c;
     
    309309}
    310310
    311 static wchar_t parse_ms_start(kbd_event_t *ev)
     311static wchar_t parse_ms_start(console_event_t *ev)
    312312{
    313313        wchar_t c;
     
    384384}
    385385
    386 static wchar_t layout_parse_ev(kbd_event_t *ev)
    387 {
    388         if (ev->type != KE_PRESS)
    389                 return '\0';
    390 
     386static wchar_t layout_parse_ev(console_event_t *ev)
     387{
     388        if (ev->type != KEY_PRESS)
     389                return 0;
     390       
    391391        if (key_is_mod(ev->key))
    392                 return '\0';
    393 
     392                return 0;
     393       
    394394        switch (mstate) {
    395         case ms_start: return parse_ms_start(ev);
    396         case ms_hacek: return parse_ms_hacek(ev);
    397         case ms_carka: return parse_ms_carka(ev);
     395        case ms_start:
     396                return parse_ms_start(ev);
     397        case ms_hacek:
     398                return parse_ms_hacek(ev);
     399        case ms_carka:
     400                return parse_ms_carka(ev);
    398401        }
    399402}
     
    401404/**
    402405 * @}
    403  */ 
     406 */
Note: See TracChangeset for help on using the changeset viewer.