Bug 304565 - Network browser: details view breaks when expanding
Summary: Network browser: details view breaks when expanding
Status: RESOLVED FIXED
Alias: None
Product: dolphin
Classification: Applications
Component: view-engine: details mode (show other bugs)
Version: 2.1
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Dolphin Bug Assignee
URL: http://www.qfpost.com/z/EXMhMS2UV.jpg
Keywords: reproducible
: 314660 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-08-04 16:32 UTC by didi156
Modified: 2013-02-27 13:04 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.11.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description didi156 2012-08-04 16:32:57 UTC
Her this happens for "Samba Shares". When I expand an item, it shows doesn't show the hierarchy as expected, but just adds the sub-items to the top hierarchy list.

Reproducible: Always
Comment 1 Frank Reininghaus 2012-08-06 10:35:27 UTC
Thanks for the bug report! I can confirm this issue. Very strange.
Comment 2 Jeroen van Meeuwen (Kolab Systems) 2012-08-24 16:22:29 UTC
Resetting assignee to default as per bug #305719
Comment 3 Frank Reininghaus 2012-11-15 08:46:36 UTC
The problem seems to be that the URLs in smb: do not follow the usual scheme

/dir/item

Therefore, KFileItemModel has trouble finding out that 'item' is a child of 'dir'. Probably KDirModel (which was used in Dolphin 1.x) does something more sophisticated to determine parent-child relationships of KFileItems...
Comment 4 Jay LaCroix 2012-11-30 01:42:55 UTC
Still an issue as of 4.9.3.
Comment 5 Jay LaCroix 2013-01-20 22:34:07 UTC
Same problem in 4.10 RC3.
Comment 6 Jay LaCroix 2013-02-07 03:46:39 UTC
Same problem in 4.10 final. Is anyone paying attention to this anymore?
Comment 7 Frank Reininghaus 2013-02-07 08:51:38 UTC
(In reply to comment #6)
> Is anyone paying attention to this anymore?

If you mean "Is anyone aware that this bug exists", the answer is yes. If you mean "Is anyone currently working on it", the answer is no.

Everyone agrees that it would be better if we could fix bugs faster, but considering that we currently have 255 open bugs and new reports are filed all the time, and that there is only a small team of volunteers with limited spare time working on Dolphin, this is just not possible. We do fix a couple of issues for each bug fix release, and we really cannot do more. (You might argue that this should not have been broken in the first place, but no current Dolphin developer was responsible for this.)

I'm currently working on improving the code that handles parent-child relationships in expanded folders for KDE 4.11 (https://git.reviewboard.kde.org/r/108766/), which fixes a few other bugs and which might make it easier to also fix this issue. But I cannot make any promises.

I see that you're probably unhappy with this reply, but I really cannot help more at the moment. Feel free to look at the code yourself and figure out what's wrong if you want to see this fixed.

I kindly ask you not to post further comments here, unless you can provide a patch to fix it. Monthly "the bug is still there" reminders are unnecessary and waste everyone's time (including your own). Thanks for your understanding.
Comment 8 Jay LaCroix 2013-02-07 13:24:36 UTC
A simple "yes, we are aware of the issue" would've done just fine.

I personally have no problem looking at the code and trying to find a fix. I'm a beginner though, so not sure how valuable I'd be. To be honest, all I would probably do is put in an if statement to disable tree view on smb:// which I think would be the quickest way to get rid of this. I don't feel that a server > share treeview relationship has any value, because you can use tree view on the contents within the share. It just doesn't need to be there on the server list if it doesn't work.
Comment 9 Frank Reininghaus 2013-02-08 10:57:13 UTC
*** Bug 314660 has been marked as a duplicate of this bug. ***
Comment 10 Pascal d'Hermilly 2013-02-08 12:47:06 UTC
Thank you ! for working on Dolphin :-)
Comment 11 Emmanuel Pescosta 2013-02-21 22:24:13 UTC
Hello didi156 and Jay, I think this patch https://git.reviewboard.kde.org/r/109045/ will solve the problem ;) 

@didi156, @Jay:
Can you please test it? Thanks
Comment 12 Jay LaCroix 2013-02-22 03:26:00 UTC
I would love to test it, but how do I apply it? Is there a DEB file somewhere?
Comment 13 Emmanuel Pescosta 2013-02-22 07:12:41 UTC
(In reply to comment #12)
> I would love to test it, but how do I apply it? Is there a DEB file
> somewhere?

Thanks for your help!

No, you have to install the build dependencies, clone the kde-baseapps repo, then apply the patch to master and compile everything.  -> A lot of work to test this patch ;)

I will ask Frank or someone else to test it, just to be sure that this patch really fixes this bug.

When KDE 4.11 will be released, then you can test it too ;) -> If this bug is also present in 4.11, we can reopen this bug report.
Comment 14 Emmanuel Pescosta 2013-02-27 13:04:09 UTC
Git commit 8008bc233d8447794df6f4cdc8c3f0ee7e8ac628 by Emmanuel Pescosta.
Committed on 27/02/2013 at 13:35.
Pushed by emmanuelp into branch 'master'.

Big Thanks to Frank Reininghaus, who helped me a lot with these
changes! :)

* Fixed the "Network browser" and "timeline" issues, by using the
KDirLister's itemsAdded(KUrl,KFileItemList) signal -> Use the
given Url to define the parent-child relationship.

* Changed the name of the slot "slotNewItems" to "slotItemsAdded"
for consistency with the signal.

* Use a QHash<KFileItem, ItemData*> instead of a QSet<KFileItem> to
store the filtered data (needed to keep the O(1) lookup for filtered
KFileItems in slotItemsDeleted + needed to fix bug 311912 "After
erasing a filter, some thumbnails randomly disappear")

* Made the determination of the "expandedParentsCount" slightly
simpler - just adding 1 to the parent's level (Also needed to fix the
"Network browser" and "timeline" issues)

FIXED-IN: 4.11.0
REVIEW: 109180
Related: bug 311912, bug 312890, bug 315593

M  +69   -64   dolphin/src/kitemviews/kfileitemmodel.cpp
M  +13   -8    dolphin/src/kitemviews/kfileitemmodel.h
M  +9    -3    dolphin/src/tests/kfileitemmodelbenchmark.cpp
M  +1    -1    dolphin/src/tests/kfileitemmodeltest.cpp

http://commits.kde.org/kde-baseapps/8008bc233d8447794df6f4cdc8c3f0ee7e8ac628