ARK-Navigator icon indicating copy to clipboard operation
ARK-Navigator copied to clipboard

Incremental sorting

Open kirillt opened this issue 3 years ago • 2 comments

Right now, sorting of resources causes small delays on huge collections (e.g. 5000 of pictures). After addition of persistence of sorting preferences, this delay is imposed after frequent actions: opening a folder and going back from gallery mode to resources grid.

It may be possible to perform sorting in a smarter way:

  1. find top T resources and put K of them into visible frame;
  2. spawn sorting of the rest of resources in background;
  3. allow the user to do his stuff.

Implementation can be non-trivial, but performance would be better: blocking phase: T * N operations to find top T resources (where N is number of all resources) background phase: normal sorting of N - T elements

kirillt avatar Sep 15 '21 18:09 kirillt

Eventually this should be implemented in the library, but it's not clear when it will be possible.

kirillt avatar Feb 03 '22 12:02 kirillt

Also, lazy shuffling (#15) could be implemented in similar fashion.

kirillt avatar Apr 18 '23 04:04 kirillt