Slow startup time on huge directories.
When eog starts it runs eog_list_store_append_directory (), which ends up iterating every file in the same directory while calling directory_visit() to possibly peek their mime type. This can be really time consuming task in slow file system or when working in huge directory. AFAIK when the gallery mode is disabled, this functionality is only needed for jumping to the previous or next picture.
If eog_list_store_append_directory() is changed to return immediately, eog for me in huge directory load instantly, if instead only directory_visit (file, file_info, store) in the loop is commented out, it also gives noticeably faster start up time.
I could be making false assumptions and I'm not too confident about my programming skills or about my knowledge about eog, but I think it would be best if the whole directory isn't iterated immediately, instead next and previous image should be loaded on demand, if their loading time is concern, they could be loaded beforehand in background, but this would probably add too much unnecessarily additional complexity?
Alternatively there could be just simple command line parameter called something like --disable-next for disabling previous/next functionality.
Disabled gallery mode could also be extended to disable next/prev, but in my honest option load on demand would be best option.
#293 #218 https://askubuntu.com/questions/1346148/image-viewer-loads-slowly-or-not-at-all-with-larger-images-20-04 https://askubuntu.com/questions/1295933/slow-image-opening-with-xdg-open-eog-in-folder-of-many-files