Review Request: Fix folderview sorting

Commit Hook null at kde.org
Thu Feb 9 18:48:32 UTC 2012


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/103895/#review10465
-----------------------------------------------------------


This review has been submitted with commit 84a2cb8b818bd5386d8f54cf515d9ac43debc547 by Ignat Semenov to branch master.

- Commit Hook


On Feb. 9, 2012, 6:22 p.m., Ignat Semenov wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/103895/
> -----------------------------------------------------------
> 
> (Updated Feb. 9, 2012, 6:22 p.m.)
> 
> 
> Review request for Plasma, Aaron J. Seigo, Marco Martin, Peter Penz, and Fredrik Höglund.
> 
> 
> Description
> -------
> 
> This patch fixes the inconsistent sorting issues in FolderView.
> 
> 1)It introduces explicit support for sorting by size. Prior to the change, sorting by Size was done as follows:convert the size into a string and use KStringHandler::naturalCompare(). Of course, this is not the same as a proper int comparison - FW sorted incorrectly by size.
> 2)Introduce one important concept:fallback to comparing the name if the main sorting column is not enough to determine a sort order. This is especially important for sorting by type - sorting by size needs this as well, but different files are way less likely to have the same size compared to the possibility of them having similar types.
> 3)Intoduce full three-level fallback for ensuring file name uniqueness, taken from Dolphin code. Thanks a bunch goes to Peter Penz :)
> 4)And of course, sort folders by the child count if sorting by size. Again, Dolphin inspired.
> 
> 
> Diffs
> -----
> 
>   plasma/applets/folderview/proxymodel.cpp 4b3340e 
> 
> Diff: http://git.reviewboard.kde.org/r/103895/diff/diff
> 
> 
> Testing
> -------
> 
> Tested, yields results similar to Dolphin sorting of the same folder (surpise! :) ).
> 
> 
> Thanks,
> 
> Ignat Semenov
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20120209/c4a774b4/attachment-0001.html>


More information about the Plasma-devel mailing list