telnet: support end and home keys
this will help navigate to the line start and end easily Change-Id: I3f42eb5267df64c59a85ece67de5fce39a8843ec Signed-off-by: Tarek BOCHKATI <tarek.bouchkati@gmail.com> Reviewed-on: http://openocd.zylin.com/6094 Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com> Tested-by: jenkins
This commit is contained in:
parent
41147e6fcd
commit
78462af05f
|
@ -596,6 +596,12 @@ static int telnet_input(struct connection *connection)
|
|||
telnet_history_up(connection);
|
||||
} else if (*buf_p == 'B') { /* cursor down */
|
||||
telnet_history_down(connection);
|
||||
} else if (*buf_p == 'F') { /* end key */
|
||||
telnet_move_cursor(connection, t_con->line_size);
|
||||
t_con->state = TELNET_STATE_DATA;
|
||||
} else if (*buf_p == 'H') { /* home key */
|
||||
telnet_move_cursor(connection, 0);
|
||||
t_con->state = TELNET_STATE_DATA;
|
||||
} else if (*buf_p == '3')
|
||||
t_con->last_escape = *buf_p;
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue