1
1

little changes to make 'completion' more intuitive.

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
Этот коммит содержится в:
Ilia Maslakov 2010-12-21 19:54:00 +00:00 коммит произвёл Andrew Borodin
родитель 65d4e1752d
Коммит e4de4f00d1

Просмотреть файл

@ -1032,11 +1032,21 @@ query_callback (Dlg_head * h, Widget * sender, dlg_msg_t msg, int parm, void *da
case KEY_BACKSPACE: case KEY_BACKSPACE:
bl = 0; bl = 0;
if (end == min_end) /* exit from completion list if input line is empty */
if (end == 0)
{ {
h->ret_value = 0; h->ret_value = 0;
dlg_stop (h); dlg_stop (h);
} }
/* Refill the list box and start again */
else if (end == min_end)
{
end = str_get_prev_char (&input->buffer[end]) - input->buffer;
input_handle_char (input, parm);
h->ret_value = B_USER;
dlg_stop (h);
return MSG_HANDLED;
}
else else
{ {
int new_end; int new_end;