Review Request: Don't make items invisible when turning off previews

Frank Reininghaus frank78ac at googlemail.com
Wed Jan 18 23:30:22 GMT 2012


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

Review request for Dolphin.


Description
-------

The problem is in KItemListView::doLayout(): This function assumes that firstVisibleIndex is a constant.

However, if the view is scrolled to the bottom with previews enabled, and then previews are disabled (and the icon size is much smaller without previews), this function changes the scroll offset, which also changes the the first visible index. Using the unchanged variable causes trouble later on (i.e., it makes items which are actually inside the view area invisible).

I'm not sure if constness assumption for lastVisibleIndex could also cause problems, so I propose to update it as well after a scroll offset change for consistency and safety.


This addresses bug 291841.
    http://bugs.kde.org/show_bug.cgi?id=291841


Diffs
-----

  dolphin/src/kitemviews/kitemlistview.cpp b6af428 

Diff: http://git.reviewboard.kde.org/r/103731/diff/diff


Testing
-------

Works for me.


Thanks,

Frank Reininghaus

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


More information about the kfm-devel mailing list