Bug 401138 - KDevelop showing duplicate contextmenu items
Summary: KDevelop showing duplicate contextmenu items
Status: RESOLVED WORKSFORME
Alias: None
Product: kdevelop
Classification: Applications
Component: UI: IDEAl (show other bugs)
Version: unspecified
Platform: Compiled Sources All
: NOR normal
Target Milestone: ---
Assignee: kdevelop-bugs-null
URL:
Keywords:
: 409340 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-11-17 14:55 UTC by RJVB
Modified: 2024-11-05 09:47 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description RJVB 2018-11-17 14:55:46 UTC
SUMMARY
Document context menu actions are added multiple times after https://phabricator.kde.org/R39:3f0c617e22ab5d2ae016ef7858c6f451f9cf0ad0

STEPS TO REPRODUCE
1. install KTextEditor from git/master
2. Open a KDevelop session that has multiple documents open
3. Open a context menu; notice how the actions below the Bookmarks submenu are shown once only

OBSERVED RESULT
4. Switch to another document, open the context menu, notice how these actions now show up twice
5. Switch to a third document, open the context menu, notice how the number of duplications increased.

ADDITIONAL INFORMATION
This is no longer dependent on having the Kate CTags plugin loaded as in my earlier reports. Instead, it is due (I think) to a design flaw in KDevelop: the QMenu added to the context menu should not be private to individual views but instead be shared among them. That is the only way the added menu actions can be removed (before adding a refreshed list of actions) when the menu is about to be reopened in another view.

Proposed fix: https://phabricator.kde.org/D16882
Comment 1 Friedrich W. H. Kossebau 2019-07-02 14:46:45 UTC
*** Bug 409340 has been marked as a duplicate of this bug. ***
Comment 2 Igor Kushnir 2024-11-05 09:47:26 UTC
Cannot reproduce in latest KDevelop master (between 6.0 and 6.1) even with the CTags plugin enabled.