[Gambas-user] right click

GuruLounge - MailLists maillists at ...1367...
Mon Mar 27 16:41:11 CEST 2006


use the "menu" event to capture the mouse right-click.  To get to this
event, right click the control you wish to add the popup, click "event"
then select "menu".  This will create the event sub you need.

To create a popup, put a hidden menu item someplace (I use a separate
form just for popup menus).  Create your menu item (like "menuMyPopup")
with all the child menu items under it.  In your "menu" event for your
control just call the menu item with the .popup extension, e.g.:

PUBLIC SUB columnview_Menu()

  FormMenus.menuMyPopup.Popup

END

This works in Gambas 1.0.13 and 1.0.14...

HTH,

Jeff


On Mon, 2006-03-27 at 07:03 +0000, mike webb wrote:
> using version 1.10
> can someone lead me to an example of right clicking on a tableview or 
> some other control and up pops the "right click menu" i don't know what 
> you call a "right click menu", but hopfully you know what i mean.
> 

-- 

     .^.
     /V\
    /( )\
    ^^-^^
Linux Advocate





More information about the User mailing list