I'm thinking to use a pulldown button and hide it so I put something in my stack script or card script like:
on mouseUp
set the visibility of the pulldown button to true
......
end mouseUp
but my question is, how can I bring the pulldown menu to the proper position(not the mouse loc)?
is there any better way of doing it??
Thank you...
pop-up menu on mouse right button click
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- VIP Livecode Opensource Backer
- Posts: 977
- Joined: Sat Apr 08, 2006 7:47 am
- Contact:
Re: pop-up menu on mouse right button click
A better option is to put your opup menu button somewhere off-screen, and then use a script like:
The popup menu button will receive the 'menuPick' message when the user picks one of the items, so you'll have to move some of your logic into that menu button as well:
Hope this helped,
Jan Schenkel.
Code: Select all
on mouseUp pMouseButton
if pMouseButton = 3 then
popup button "MyPopupButton" at the clickLoc
else
-- do other stuff here
end if
end mouseUp
Code: Select all
on menuPick pItem
switch pItem
case "Hello world"
answer "Hello, world!"
break
case "Foo"
answer "Bar" with "Cancel"
break
-- more case statements here
end switch
end menuPick
Jan Schenkel.
Quartam Reports & PDF Library for LiveCode
www.quartam.com
www.quartam.com