Bug 403454

Summary: Multiple "unmount" entries
Product: [Frameworks and Libraries] frameworks-kio Reporter: tgnff242
Component: URL navigatorAssignee: David Faure <faure>
Status: RESOLVED FIXED    
Severity: normal CC: bugseforuns, kde, kdelibs-bugs-null, nate, valizadeh.ho
Priority: NOR    
Version First Reported In: 5.54.0   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Screenshot that presents the issue.

Description tgnff242 2019-01-21 09:10:10 UTC
Created attachment 117583 [details]
Screenshot that presents the issue.

SUMMARY
Navigating through a mounted partition, _without_ the places panel active, creates multiple "unmount" entries in the location bar. Same for external devices, but it says "Safely remove" instead. Usually, I have the places panel active, so I'm unsure as to when the bug was introduced.

STEPS TO REPRODUCE
0. Disable the Places panel in dolphin.
1. Mount a partition, or plug in a usb stick.
2. Navigate with dolphin through the directories of the partition.

OBSERVED RESULT
When you click at the icon of the partition/device on the left of the location bar, there arre multiple entries to unmount/safely_remove the partition/device. The more you navigated through the dirs, the more entries will be present.

SOFTWARE/OS VERSIONS
KDE Plasma Version: 5.14.5
KDE Frameworks Version: 5.54.0
Qt Version: 5.12.0
Comment 1 Kai Uwe Broulik 2019-01-21 09:39:14 UTC
Probably a bug in KUrlNavigator, re-assigning to KIO
Comment 2 Kai Uwe Broulik 2019-01-21 09:49:43 UTC
Patch https://phabricator.kde.org/D18425
Comment 3 tgnff242 2019-01-21 11:21:24 UTC
The patch seems to work nicely except for when you open Dolphin through the Device Notifier (the popup that asks you what you want to do when a device is plugged in), in which case there are two entries to safely remove the device (one at the top and one at the bottom).
Comment 4 Kai Uwe Broulik 2019-01-21 11:52:23 UTC
I can confirm. Perhaps because the Unmount entry is added and only after that the menu is populated.
Comment 5 Patrick Silva 2019-02-20 19:35:16 UTC
*** Bug 404499 has been marked as a duplicate of this bug. ***
Comment 6 Kai Uwe Broulik 2019-09-16 11:56:29 UTC
Git commit 8e3b39635cb54ac8b8158701a2620af4228a7508 by Kai Uwe Broulik.
Committed on 16/09/2019 at 11:56.
Pushed by broulik into branch 'master'.

[KUrlNavigatorPlacesSelector] Properly identify teardown action

Rather than relying on the model count (which broke when we added places categories), just identify the action by the data it is given.

Differential Revision: https://phabricator.kde.org/D18425

M  +12   -15   src/filewidgets/kurlnavigatorplacesselector.cpp

https://commits.kde.org/kio/8e3b39635cb54ac8b8158701a2620af4228a7508