Details
-
Suggestion
-
Resolution: Unresolved
-
Not Evaluated
-
None
-
None
-
None
Description
With Qt 5.15 almost being finished, this probably would be something for Qt 6, but however:
It would be nice if one could find out if a directory is on a network mount or not cross-platform.
On Linux, this seems to be possible via QStorageInfo. If I go through QStorageInfo::mountedVolumes(), I can check fileSystemType(). So I e. g. get nfs4, cifs or fuse.sshfs for network mounts.
On Windows however, for a Samba share, I get NTFS, as if the share was a normal local file system.
At least on Windows, it seems to be possible to distinguish a local drive from a remote one using GetDriveTypeA: https://docs.microsoft.com/de-de/windows/win32/api/fileapi/nf-fileapi-getdrivetypea – but nobody wants to mess with the Windows API
It would be nice if QStorageInfo was extended by such functionality.