Changeset 68f1254c in mainline
- Timestamp:
- 2018-12-30T11:49:13Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- e8d3165e
- Parents:
- 59cce22
- Location:
- uspace/lib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/io/chargrid.c
r59cce22 r68f1254c 263 263 void chargrid_set_cursor(chargrid_t *scrbuf, sysarg_t col, sysarg_t row) 264 264 { 265 if (col >= scrbuf->cols || row >= scrbuf->rows) 266 return; 267 265 268 scrbuf->col = col; 266 269 scrbuf->row = row; -
uspace/lib/clui/tinput.c
r59cce22 r68f1254c 56 56 } seek_dir_t; 57 57 58 static void tinput_update_origin(tinput_t *); 58 59 static void tinput_init(tinput_t *); 59 60 static void tinput_insert_string(tinput_t *, const char *); … … 71 72 static void tinput_console_set_lpos(tinput_t *ti, unsigned lpos) 72 73 { 73 console_set_pos(ti->console, LIN_TO_COL(ti, lpos), 74 LIN_TO_ROW(ti, lpos)); 74 unsigned col = LIN_TO_COL(ti, lpos); 75 unsigned row = LIN_TO_ROW(ti, lpos); 76 77 assert(col < ti->con_cols); 78 assert(row < ti->con_rows); 79 console_set_pos(ti->console, col, row); 75 80 } 76 81 … … 163 168 static void tinput_position_caret(tinput_t *ti) 164 169 { 170 tinput_update_origin(ti); 165 171 tinput_console_set_lpos(ti, ti->text_coord + ti->pos); 166 172 } … … 232 238 233 239 tinput_display_tail(ti, ti->pos - 1, 0); 234 tinput_update_origin(ti);235 240 tinput_position_caret(ti); 236 241 } … … 276 281 277 282 tinput_display_tail(ti, ti->pos - ilen, 0); 278 tinput_update_origin(ti);279 283 tinput_position_caret(ti); 280 284 }
Note:
See TracChangeset
for help on using the changeset viewer.