Bug 452352

Summary: Calculate total directory size
Product: [Applications] ark Reporter: Dan Dascalescu <ddascalescu+kde>
Component: generalAssignee: Andrey <butirsky>
Severity: wishlist CC: aacid, butirsky, nate, rthomsen6
Priority: NOR    
Version: 21.12.3   
Target Milestone: ---   
Platform: Other   
OS: Linux   
URL: https://invent.kde.org/utilities/ark/-/merge_requests/114
Latest Commit: Version Fixed In: 22.08
Sentry Crash Report:
Attachments: Fodler size shows number of files and folders in 7Z archive

Description Dan Dascalescu 2022-04-07 03:09:36 UTC
Created attachment 148013 [details]
Fodler size shows number of files and folders in 7Z archive

Trying to see which directories take up the most space inside an archive, is impossible with Ark because it only shows the number of folders and files in the folder.

IIRC, File Roller was able to show directory size.
Comment 1 Andrey 2022-04-14 08:37:49 UTC
I'm going to look at this
Comment 2 Andrey 2022-04-22 11:25:25 UTC
Git commit 3981425a61c544a99ad7ab0c7228464e6430eb08 by Andrey Butirsky.
Committed on 22/04/2022 at 09:45.
Pushed by butirsky into branch 'master'.

Calculate total directory size

M  +9    -12   part/archivemodel.cpp
M  +1    -2    part/archivemodel.h
M  +1    -1    part/infopanel.cpp
M  +13   -7    part/part.cpp

Comment 3 Andrey 2022-04-22 12:29:30 UTC
Ragnar, could you follow up on your comment here?
> When ArchiveModel has been properly fixed, this code can likely be removed.
Comment 4 Andrey 2022-04-22 13:56:14 UTC
Please note the sizes calculation in the patch is synchronous.
If anyone had opportunity to test it on really big archives to estimate performance penalty, that would be helpful.