[Lazarus] TListView and TPopupMenu and the right mouse button

Paul Ishenin ip at kmiac.ru
Tue Aug 3 02:32:17 CEST 2010


03.08.2010 7:37, Bernd Kreuss wrote:
> This might be a stupid question but I'm not 100% sure how to proceed
> from here. There seems to be a bug in TListView on GTK2 that impacts the
> usage of the right mouse button as soon as there is a popup menu defined
> for it.

Yes. This is how we designed the right click handling for gtk2. If we 
allow the default action to happen then you can suddenly see 2 popup 
menus: one your and one standard - for example for TEdit or TPageConrol 
(since gtk2 will handle the right click and will show a popup on it and 
LCL will do the same).

> My first idea was to simply leave the PopupMenu property completely
> empty and simply show the menu manually on mouse down. But I cannot find
> any example how to manually open a menu that was designed in the form
> designer?

PopupMenu.PopupAt();

Best regards,
Paul Ishenin.





More information about the Lazarus mailing list