sHagen wrote:In a folder with many files, this can be pretty slow.
I have a folder with 6000 files. If I search for "alex", it goes like this:
"a"<4 seconds, 4k hits>
"al"<1 second, 700 hits>
"ale"<almost instant, 40 hits>
Indeed that could be slow. As you may understand, the reason it get progressively faster is because there are less items to search and less items to re-order (on screen) once the search narrows down.
sHagen wrote:When deleting the search term via backspace it takes those combined 5+ seconds again. On less powerful CPUs it takes a lot longer.
Yes that would be expected behavior in reverse.
sHagen wrote:Would it be possbible to allow us to deactivate this and search on hitting return?
Or to introduce a delay so the search is triggered after 1 second without keypress?
Or start searching on the third character?
Some good ideas here ... Exactly what I had in mind in fact. It's not unusual to start searching from minimum three characters (little chance anyone is searching files with a single character) and that should perhaps be a new default. I think also we could have options for search on keypress-timeout and search on return keypress (+ search button). It could also be an idea implement behavior based on the amount of files in the folder ... For example, if there are less than 100 files, it really doesn't hurt to have instant search.
FYI: I think the reason for long delays isn't the search itself, but re-sorting thousands of DOM elements in the browser on keypress.
I'll look into this for next release, which will get started in a few weeks. Thanks for posting!