D22424: TextDocument: remove actions from contextmenu on hide already
René J.V. Bertin
noreply at phabricator.kde.org
Thu Jul 18 13:11:01 BST 2019
rjvbb added a comment.
> >> > FWIW I got to look at the KTE implementation of the context menu mechanism that is used here. It indeed uses and reuses a single QMenu instance (there's even a comment in the code about that).
> >>
> >> Please give links into the code, as I am lost what you exactly refer to here.
> >
> > see the source of `KTextEditor::ViewPrivate::contextMenu()`. The ctx menu is in fact managed by KXMLGUI.
>
> The context menu is queried every time from KXMLGUI that method is called. So if KXMLGUI internally decides to recreate the context menu, you get another object the next time. Please see again the description of this very bug.
Since we're dealing with "please read/see again": idem for my comment :P which only states that a single QMenu instance is being (re)used. I've never seen it change but I without trying to understand the KXMLGUI internals (or docs) I will have to assume that this is possible. That's moot though, I've been only been saying that the ctx menu instance should probably be cached in a more central location.
REPOSITORY
R32 KDevelop
REVISION DETAIL
https://phabricator.kde.org/D22424
To: kossebau, #kdevelop
Cc: anthonyfieroni, rjvbb, kdevelop-devel, hmitonneau, christiant, glebaccon, domson, antismap, iodelay, alexeymin, geetamc, Pilzschaf, akshaydeo, surgenight, arrowd
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20190718/f80245da/attachment-0001.html>
More information about the KDevelop-devel
mailing list