Review Request 118128: Use actual bytes formatter for sizes in KDirModel
Frank Reininghaus
frank78ac at googlemail.com
Wed May 14 14:41:27 UTC 2014
> On May 14, 2014, 2:24 p.m., David Faure wrote:
> > It is correct that this is about a string representation of the filesize, to displaying in a column of the model.
> > For machine processing one can use KFileItem::size() after getting the KFileItem out of the KDirModel.
> >
> > However, do we really want that the detailed listview in dolphin? I can more easily recognize the biggest number by being the one with most digits, than having to go through a list of kB, MB, and GB values.
> >
> > It might even break the sorting by size.
> >
> > Let's ask Frank Reininghaus, but I'm not sure this is a good idea.
I might not have fully understood what exactly this patch will change in the GUI - both the file dialog (which uses KDirModel) and Dolphin already do show "B/KiB/MiB/etc." values in the detailed view here (on a system with the rather old KDE SC 4.10.5 - I currently don't have anything else to test here), but maybe something changed about that in frameworks?
If QSortFilterProxyModel uses the value returned by the function that is modified by this patch (I think it does?), then this might really break sorting by size in the dialog. Have you checked this, Martin?
- Frank
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/118128/#review57923
-----------------------------------------------------------
On May 14, 2014, 2:01 p.m., Martin Klapetek wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/118128/
> -----------------------------------------------------------
>
> (Updated May 14, 2014, 2:01 p.m.)
>
>
> Review request for KDE Frameworks and David Faure.
>
>
> Repository: kio
>
>
> Description
> -------
>
> Now I'm not sure if returning the unit together with the size won't break some things, but as it returns string already, I thought returning it in the "human readable" form would be better than always returning bytes.
>
>
> Diffs
> -----
>
> src/widgets/kdirmodel.cpp 70d5ee4
>
> Diff: https://git.reviewboard.kde.org/r/118128/diff/
>
>
> Testing
> -------
>
>
> Thanks,
>
> Martin Klapetek
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20140514/d2aefc34/attachment.html>
More information about the Kde-frameworks-devel
mailing list