PreviewJob: Consider slow files as remote files in previewjob
This reverts commit be7d351a.
Original author: Bharadwaj Raju (!702 (merged)).
The reason is still the same, when mounting a remote network folder via davfs2
(or rclone
, etc) as a local mount point (and potentially other remote FS, like sshfs and so on) for PreviewJob these are local files, and therefore it tries to create thumbnails for such files in accordance with the limits of the maximum size of local files (which are usually unlimited), which forces davfs2
to download all files from a remote folder in order to create thumbnails.
This change will take into account that the files are slow - that is, remote network files, and will impose maximum size restrictions on them for remote NETWORK files when building thumbnails (which is usually 0).
This change was previously canceled for two reasons, it seems to me:
-
Before the change kcoreaddons!255 (merged) all FUSE devices, including flash drives and NTFS, were defined as NFS and, accordingly, because of this change, file size limits were applied on such, even local FS, as for network files, and, accordingly, most often thumbnails were not built.
-
Thumbnails for remoted deleted directories are clearly disabled. Some people have encountered such a problem that they want to display thumbnails even for locally mounted remote FS, since they are located on a local network or they simply do not have a problem with the speed of the network channel (read more here https://bugs.kde.org/show_bug.cgi?id=450482).
I suggest MR (!1533 (merged)), in which I made thumbnail displays for remote directories mounted as local ones in accordance with the maximumRemoteSize limit, so that those who want to display thumbnails on such remote FS can do this.