summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2014-02-09 16:11:15 +0100
committerYorhel <git@yorhel.nl>2014-02-10 13:52:33 +0100
commit2c845d9bbe721a63f85a889e517178ae3eb8d464 (patch)
tree7108e4611bec64c1c7415f978842c6efa9e05f79
parentc60848d9936a34fb4ca7eaa624813e0fd59b2004 (diff)
search: Start searching from selected item instead of from top
Certainly vim and vifm start searching from the cursor rather than the start of the file/listing. I'd expect most other applications to do the same.
-rw-r--r--src/ui_util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ui_util.c b/src/ui_util.c
index 2b76bb6..97ce0e0 100644
--- a/src/ui_util.c
+++ b/src/ui_util.c
@@ -1231,7 +1231,7 @@ static void ui_listing_search(ui_listing_t *ul, guint64 key) {
} else {
// some other key pressed -> update search
ul->query = ui_textinput_get(ul->search_box);
- ui_listing_search_advance(ul, ui_listing_getbegin(ul), FALSE);
+ ui_listing_search_advance(ul, ul->sel, FALSE);
}
}