Review Request 111399: Keep the "item size hints" of moved items

Mark Gaiser markg85 at gmail.com
Fri Jul 5 07:56:07 BST 2013


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


Hi Frank,

This is awesome, but i'm a bit concerned about the "m_sizeHintCache". That value is a member of KItemListSizeHintResolver which is kept for the life of KItemListView. Which, if i'm correct, is as long as dolphin is running. So m_sizeHintCache can get quite large if you open massively sized folders, right? So perhaps it's an idea to to apply an LRU algorithm here to keep the cache size down to a certain defined maximum. Perhaps QQcache can do this for you?

For all of this, it's just an assumption and something i noticed. I don't know if it's actually the case. Please do correct me if i'm wrong :)

- Mark Gaiser


On July 4, 2013, 10:20 p.m., Frank Reininghaus wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/111399/
> -----------------------------------------------------------
> 
> (Updated July 4, 2013, 10:20 p.m.)
> 
> 
> Review request for Dolphin.
> 
> 
> Description
> -------
> 
> Calculating the "item size hint", i.e., the size that is required to show an item including its full name, is quite expensive in Icons and Compact View. Therefore, it makes sense to keep them even if items are moved (the current code just throws them away and recalculates them the next time KItemListViewLayouter::doLayout() is called).
> 
> 
> Diffs
> -----
> 
>   dolphin/src/kitemviews/kitemlistview.cpp 2ea6657 
>   dolphin/src/kitemviews/private/kitemlistsizehintresolver.h 5ec5f4a 
>   dolphin/src/kitemviews/private/kitemlistsizehintresolver.cpp 5db87f3 
> 
> Diff: http://git.reviewboard.kde.org/r/111399/diff/
> 
> 
> Testing
> -------
> 
> When enabling the timer in KItemListViewLayouter::doLayout(), I see that the time required for a relayouting after changing the sort order or renaming a file is decreased significantly.
> 
> 
> Thanks,
> 
> Frank Reininghaus
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20130705/3cad5c07/attachment.htm>


More information about the kfm-devel mailing list