Bug 446084

Summary: Status bar is not updated after a selected file’s size is changed
Product: [Applications] dolphin Reporter: Frank Steinmetzger <dev+kde>
Component: bars: statusAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: CONFIRMED ---    
Severity: normal CC: kfm-devel, p.r.worrall
Priority: NOR    
Version: 21.08.3   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Screenshot showing the problem

Description Frank Steinmetzger 2021-11-25 18:51:20 UTC
SUMMARY
Dolphin updates the main view when a file has been changed in another application. For instance, when an image has been made smaller, dolphin updates its file size in the details view. If that file is part of a selection, the selection info is not updated.

STEPS TO REPRODUCE
1. Select several files in Dolphin
2. The accumulated size of the selected files is displayed in the status bar
3. Change one of the selected files

OBSERVED RESULT
Dolphin updates the file’s item in the main view, but not the accumulated file size in the status bar.

EXPECTED RESULT
The status bar shall be updated as well.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.23.3
KDE Frameworks Version: 5.88.0
Qt Version: 5.15.2
Kernel Version: 5.15.2-arch1-1 (64-bit)
Graphics Platform: X11
Processors: 4 × Intel® Core™ i5-5200U CPU @ 2.20GHz
Memory: 15.5 GiB of RAM
Graphics Processor: Mesa Intel® HD Graphics 5500

There is an identical report at https://bugs.kde.org/show_bug.cgi?id=154733, but because that was fixed and now we are in a different framework, I thought I’d create a new one instead of reopening the old one.
Comment 1 Paul Worrall 2021-11-26 13:42:44 UTC
I can't reproduce this error, here's what I did:

1.  In an empty folder, use Dolphin right-click menu to create two empty text files (Dolphin actually creates them with a size of 2B each but that's another bug)
2. Select Details view mode in Dolphin so the file sizes are displayed
3. Open one in KWrite
4. Select both files in Dolphin. Status bar now shows "2 Files selected (4B)", and both files have a size of 2B in the main window
5. Add some text to the file that's open in KWrite and save
6. In Dolphin, the status bar now shows "2 Files selected (29B)", and the files have sizes of 2B and 27B in the main window

Do the same steps show the error in your installation?

Operating System: KDE neon 5.23
KDE Plasma Version: 5.23.3
KDE Frameworks Version: 5.88.0
Qt Version: 5.15.3
Kernel Version: 5.11.0-40-generic (64-bit)
Graphics Platform: Wayland
Processors: 2 × AMD A6-6400K APU with Radeon(tm) HD Graphics
Memory: 7.7 GiB of RAM
Graphics Processor: AMD CEDAR
Comment 2 Frank Steinmetzger 2021-11-26 15:20:47 UTC
Created attachment 143969 [details]
Screenshot showing the problem

Here’s a screenie of a demo. I created two files of 2 MiB each with dd, then selected both and then changed one file by echoing empty content into one of them.
Comment 3 Paul Worrall 2021-11-26 16:10:45 UTC
Thanks for the screenshot, I can reproduce the error using that method.