Bug 417851

Summary: Status bar shows free space in file system as "unknown" when Dolphin is opened via context menu of desktop
Product: [Frameworks and Libraries] frameworks-kio Reporter: Patrick Silva <bugseforuns>
Component: generalAssignee: David Faure <faure>
Status: RESOLVED FIXED    
Severity: normal CC: kdelibs-bugs, kfm-devel, meven29, nate
Priority: NOR    
Version: 5.67.0   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In: 5.20.0
Sentry Crash Report:
Attachments: Dolphin opened via context menu of desktop - "unknown" free space
Dolphin after I open "Desktop" icon in my Home

Description Patrick Silva 2020-02-18 23:37:31 UTC
Created attachment 126147 [details]
Dolphin opened via context menu of desktop - "unknown" free space

STEPS TO REPRODUCE
1. right click on desktop > open with dolphin
2. 
3. 

OBSERVED RESULT
status bar says "unknown" free space.
If I open Dolphin and click on "Desktop" icon in my Home, status bar shows the free space available as expected. Compare the attached screenshots please.

EXPECTED RESULT
status bar always should show the free space available in file system.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.18.1
KDE Frameworks Version: 5.67.0
Qt Version: 5.14.1
Comment 1 Patrick Silva 2020-02-18 23:38:57 UTC
Created attachment 126148 [details]
Dolphin after I open "Desktop" icon in my Home
Comment 2 Nate Graham 2020-02-19 21:00:59 UTC
Bug in the desktop:/ ioslave.

Why do we even have this ioslave...
Comment 3 Christoph Feck 2020-02-19 21:40:13 UTC
Because xdg-user-dirs wasn't a thing when KDE was born. Hardcoding ~/Desktop wasn't an option, because developers wanted an international user base right from the beginning.
Comment 4 Nate Graham 2020-02-19 21:44:50 UTC
Thanks for the history. Now that xdg dirs do exist, is there any real reason to keep it around other than compatibility?
Comment 5 Ahmad Samir 2020-05-25 11:34:59 UTC
Git commit 065ba968018f5afe0d42507d7fcf16f1d62977e1 by Ahmad Samir.
Committed on 25/05/2020 at 11:34.
Pushed by ahmadsamir into branch 'master'.

[kio_desktop] Implement SlaveBase::GetFileSystemFreeSpace

This enables reporting the actual free space info for desktop:/ in e.g.
the Dolphin status bar.

FIXED-IN: 5.19.80

M  +27   -2    kioslave/desktop/kio_desktop.cpp
M  +5    -0    kioslave/desktop/kio_desktop.h

https://invent.kde.org/plasma/plasma-workspace/commit/065ba968018f5afe0d42507d7fcf16f1d62977e1