Changeset a46e56b in mainline for uspace/lib/c/generic/io/input.c
- Timestamp:
- 2018-03-22T06:49:35Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 77f0a1d
- Parents:
- 3e242d2
- git-author:
- Jakub Jermar <jakub@…> (2018-03-21 23:29:06)
- git-committer:
- Jakub Jermar <jakub@…> (2018-03-22 06:49:35)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/io/input.c
r3e242d2 ra46e56b 43 43 #include <stdlib.h> 44 44 45 static void input_cb_conn(cap_call_handle_t i id, ipc_call_t *icall, void *arg);45 static void input_cb_conn(cap_call_handle_t icall_handle, ipc_call_t *icall, void *arg); 46 46 47 47 errno_t input_open(async_sess_t *sess, input_ev_ops_t *ev_ops, … … 92 92 } 93 93 94 static void input_ev_active(input_t *input, cap_call_handle_t c allid,94 static void input_ev_active(input_t *input, cap_call_handle_t chandle, 95 95 ipc_call_t *call) 96 96 { 97 97 errno_t rc = input->ev_ops->active(input); 98 async_answer_0(c allid, rc);99 } 100 101 static void input_ev_deactive(input_t *input, cap_call_handle_t c allid,98 async_answer_0(chandle, rc); 99 } 100 101 static void input_ev_deactive(input_t *input, cap_call_handle_t chandle, 102 102 ipc_call_t *call) 103 103 { 104 104 errno_t rc = input->ev_ops->deactive(input); 105 async_answer_0(c allid, rc);106 } 107 108 static void input_ev_key(input_t *input, cap_call_handle_t c allid,105 async_answer_0(chandle, rc); 106 } 107 108 static void input_ev_key(input_t *input, cap_call_handle_t chandle, 109 109 ipc_call_t *call) 110 110 { … … 121 121 122 122 rc = input->ev_ops->key(input, type, key, mods, c); 123 async_answer_0(c allid, rc);124 } 125 126 static void input_ev_move(input_t *input, cap_call_handle_t c allid,123 async_answer_0(chandle, rc); 124 } 125 126 static void input_ev_move(input_t *input, cap_call_handle_t chandle, 127 127 ipc_call_t *call) 128 128 { … … 135 135 136 136 rc = input->ev_ops->move(input, dx, dy); 137 async_answer_0(c allid, rc);138 } 139 140 static void input_ev_abs_move(input_t *input, cap_call_handle_t c allid,137 async_answer_0(chandle, rc); 138 } 139 140 static void input_ev_abs_move(input_t *input, cap_call_handle_t chandle, 141 141 ipc_call_t *call) 142 142 { … … 153 153 154 154 rc = input->ev_ops->abs_move(input, x, y, max_x, max_y); 155 async_answer_0(c allid, rc);156 } 157 158 static void input_ev_button(input_t *input, cap_call_handle_t c allid,155 async_answer_0(chandle, rc); 156 } 157 158 static void input_ev_button(input_t *input, cap_call_handle_t chandle, 159 159 ipc_call_t *call) 160 160 { … … 167 167 168 168 rc = input->ev_ops->button(input, bnum, press); 169 async_answer_0(c allid, rc);170 } 171 172 static void input_cb_conn(cap_call_handle_t i id, ipc_call_t *icall, void *arg)169 async_answer_0(chandle, rc); 170 } 171 172 static void input_cb_conn(cap_call_handle_t icall_handle, ipc_call_t *icall, void *arg) 173 173 { 174 174 input_t *input = (input_t *)arg; … … 176 176 while (true) { 177 177 ipc_call_t call; 178 cap_call_handle_t c allid= async_get_call(&call);178 cap_call_handle_t chandle = async_get_call(&call); 179 179 180 180 if (!IPC_GET_IMETHOD(call)) { … … 185 185 switch (IPC_GET_IMETHOD(call)) { 186 186 case INPUT_EVENT_ACTIVE: 187 input_ev_active(input, c allid, &call);187 input_ev_active(input, chandle, &call); 188 188 break; 189 189 case INPUT_EVENT_DEACTIVE: 190 input_ev_deactive(input, c allid, &call);190 input_ev_deactive(input, chandle, &call); 191 191 break; 192 192 case INPUT_EVENT_KEY: 193 input_ev_key(input, c allid, &call);193 input_ev_key(input, chandle, &call); 194 194 break; 195 195 case INPUT_EVENT_MOVE: 196 input_ev_move(input, c allid, &call);196 input_ev_move(input, chandle, &call); 197 197 break; 198 198 case INPUT_EVENT_ABS_MOVE: 199 input_ev_abs_move(input, c allid, &call);199 input_ev_abs_move(input, chandle, &call); 200 200 break; 201 201 case INPUT_EVENT_BUTTON: 202 input_ev_button(input, c allid, &call);202 input_ev_button(input, chandle, &call); 203 203 break; 204 204 default: 205 async_answer_0(c allid, ENOTSUP);205 async_answer_0(chandle, ENOTSUP); 206 206 } 207 207 }
Note:
See TracChangeset
for help on using the changeset viewer.