Bug 395211

Summary: Hide service menu groups if none of the child is active
Product: [Applications] dolphin Reporter: Simone Gaiarin <simgunz>
Component: generalAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: CONFIRMED ---    
Severity: normal CC: bugseforuns, elvis.angelaccio, fdelgado.it, justin.zobel, kde
Priority: NOR    
Version First Reported In: 18.04.1   
Target Milestone: ---   
Platform: Manjaro   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Simone Gaiarin 2018-06-10 13:27:53 UTC
In dolphin it is possible to enable and disable the service menu items individually. If all the items of a group are disabled the group is still shown in dolphin context menu, but without any child. This should be hidden instead.

Example:
The popular collection of service menus https://store.kde.org/p/998464/ provides a lot of service menus. If I don't need some of them I disable them in the dolphin settings. For example I don't need the MEGA-Tools, so I disable all of them, but I can still see the Mega-Tools entry in the context menu even though no sub items are present.
Comment 1 Kai Uwe Broulik 2018-06-27 14:58:58 UTC
I cannot reproduce. I unchecked all "Android Services", for example, and the menu entry was gone.
Comment 2 Simone Gaiarin 2018-06-27 17:03:48 UTC
Indeed disabling all the "Android Tools" removes the menu entry. Though with "Mega Tools" or "Dropbox tools" for example the menu entry is not removed.
Comment 3 Rog131 2018-07-10 18:03:19 UTC
*** Bug 396377 has been marked as a duplicate of this bug. ***
Comment 4 Justin Zobel 2020-10-26 04:02:52 UTC
(In reply to Simone Gaiarin from comment #2)
> Indeed disabling all the "Android Tools" removes the menu entry. Though with
> "Mega Tools" or "Dropbox tools" for example the menu entry is not removed.

Sounds like an issue with the plugin provided on the store, feedback should be provided to the author instead of the KDE team.
Comment 5 Simone Gaiarin 2020-10-26 06:17:59 UTC
In bug https://bugs.kde.org/show_bug.cgi?id=396377 the response of a developer of the service menu says that they have no control over this issue.

If this is not the case, can you point out the documentation of dolphin where it is explained how to hide an empty menu so that we can inform the developers of the service menus?
Comment 6 Justin Zobel 2020-10-26 06:32:11 UTC
> Indeed disabling all the "Android Tools" removes the menu entry.

I was basing off of this comment that if you do remove menu entries the parent does go away, so the parent item is being removed for empty groups.

I am not a developer so sadly I cannot provide a hint on where said functionality might be within the code. I am simply revisiting old bugs to try and clean the bug tracker up where I can.
Comment 7 Simone Gaiarin 2020-10-26 06:40:42 UTC
No worries. I changed the status to CONFIRMED, given that it was reported by another user in the duplicate bug.