Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/io/input.c

    r60ebe63 r8edec53  
    11/*
    2  * Copyright (c) 2022 Jiri Svoboda
     2 * Copyright (c) 2021 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    106106static void input_ev_key(input_t *input, ipc_call_t *call)
    107107{
    108         unsigned kbd_id;
    109108        kbd_event_type_t type;
    110109        keycode_t key;
     
    113112        errno_t rc;
    114113
    115         kbd_id = ipc_get_arg1(call);
    116         type = ipc_get_arg2(call);
    117         key = ipc_get_arg3(call);
    118         mods = ipc_get_arg4(call);
    119         c = ipc_get_arg5(call);
    120 
    121         rc = input->ev_ops->key(input, kbd_id, type, key, mods, c);
     114        type = ipc_get_arg1(call);
     115        key = ipc_get_arg2(call);
     116        mods = ipc_get_arg3(call);
     117        c = ipc_get_arg4(call);
     118
     119        rc = input->ev_ops->key(input, type, key, mods, c);
    122120        async_answer_0(call, rc);
    123121}
     
    125123static void input_ev_move(input_t *input, ipc_call_t *call)
    126124{
    127         unsigned pos_id;
    128125        int dx;
    129126        int dy;
    130127        errno_t rc;
    131128
    132         pos_id = ipc_get_arg1(call);
    133         dx = ipc_get_arg2(call);
    134         dy = ipc_get_arg3(call);
    135 
    136         rc = input->ev_ops->move(input, pos_id, dx, dy);
     129        dx = ipc_get_arg1(call);
     130        dy = ipc_get_arg2(call);
     131
     132        rc = input->ev_ops->move(input, dx, dy);
    137133        async_answer_0(call, rc);
    138134}
     
    140136static void input_ev_abs_move(input_t *input, ipc_call_t *call)
    141137{
    142         unsigned pos_id;
    143138        unsigned x;
    144139        unsigned y;
     
    147142        errno_t rc;
    148143
    149         pos_id = ipc_get_arg1(call);
    150         x = ipc_get_arg2(call);
    151         y = ipc_get_arg3(call);
    152         max_x = ipc_get_arg4(call);
    153         max_y = ipc_get_arg5(call);
    154 
    155         rc = input->ev_ops->abs_move(input, pos_id, x, y, max_x, max_y);
     144        x = ipc_get_arg1(call);
     145        y = ipc_get_arg2(call);
     146        max_x = ipc_get_arg3(call);
     147        max_y = ipc_get_arg4(call);
     148
     149        rc = input->ev_ops->abs_move(input, x, y, max_x, max_y);
    156150        async_answer_0(call, rc);
    157151}
     
    159153static void input_ev_button(input_t *input, ipc_call_t *call)
    160154{
    161         unsigned pos_id;
    162155        int bnum;
    163156        int press;
    164157        errno_t rc;
    165158
    166         pos_id = ipc_get_arg1(call);
    167         bnum = ipc_get_arg2(call);
    168         press = ipc_get_arg3(call);
    169 
    170         rc = input->ev_ops->button(input, pos_id, bnum, press);
     159        bnum = ipc_get_arg1(call);
     160        press = ipc_get_arg2(call);
     161
     162        rc = input->ev_ops->button(input, bnum, press);
    171163        async_answer_0(call, rc);
    172164}
     
    174166static void input_ev_dclick(input_t *input, ipc_call_t *call)
    175167{
    176         unsigned pos_id;
    177168        int bnum;
    178169        errno_t rc;
    179170
    180         pos_id = ipc_get_arg1(call);
    181         bnum = ipc_get_arg2(call);
    182 
    183         rc = input->ev_ops->dclick(input, pos_id, bnum);
     171        bnum = ipc_get_arg1(call);
     172
     173        rc = input->ev_ops->dclick(input, bnum);
    184174        async_answer_0(call, rc);
    185175}
Note: See TracChangeset for help on using the changeset viewer.