![]() Registered Member ![]()
|
Hello,
I've got a little problem with a few UDSEntry that represent virtual folders: in my code I place a size for each entry like the following but when I right click on the folder from konqueror and ask for the folder size it always displays zero bytes.
I've checked that the value (2000) in this case is effectively placed into the UDSEntry. Am I misunderstanding the size attribute? |
![]() KDE Developer ![]()
|
The size of a folder (as shown in the properties dialog) is the sum of the size of all the contents of the folder.
Not UDS_SIZE, which is the size of the item itself, which makes no sense for folders (e.g. on an ext3 filesystem, a folder entry takes 1K or 2K or 4K on disk, as shown by ls -l, but the user doesn't really care about that, so konqueror/dolphin doesn't display that). You should check whether listDir is correctly implemented, and whether files themselves have a UDS_SIZE -- that's what kpropertiesdialog sums up. If you only display folders, no files, then there's a problem indeed ![]() Maybe KIO itself can be changed to take into account UDS_SIZE for folders, after double-checking that none of the existing kioslaves set that... |
Registered users: bartoloni, Bing [Bot], Evergrowing, Google [Bot], ourcraft