Commit d23a7074 authored by Andreas Hammer's avatar Andreas Hammer
Browse files

Fixed completion dialog wrap arround navigation

parent 2b99c04d
Pipeline #266357795 passed with stages
in 18 minutes and 57 seconds
......@@ -432,6 +432,10 @@ bool CompletionDialog::on_key_press(GdkEventKey *event) {
list_view_text.set_cursor(list_view_text.get_model()->get_path(it));
cursor_changed();
}
else {
list_view_text.set_cursor(list_view_text.get_model()->get_path(list_view_text.get_model()->children().begin()));
cursor_changed();
}
}
else
list_view_text.set_cursor(list_view_text.get_model()->get_path(list_view_text.get_model()->children().begin()));
......@@ -446,6 +450,14 @@ bool CompletionDialog::on_key_press(GdkEventKey *event) {
list_view_text.set_cursor(list_view_text.get_model()->get_path(it));
cursor_changed();
}
else {
auto last_it = list_view_text.get_model()->children().end();
last_it--;
if(last_it) {
list_view_text.set_cursor(list_view_text.get_model()->get_path(last_it));
cursor_changed();
}
}
}
else {
auto last_it = list_view_text.get_model()->children().end();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment