Using right-click to select an element in a "list" field

Anything beyond the basics in using the LiveCode language. Share your handlers, functions and magic here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Pierre1234
Posts: 3
Joined: Sat Jun 06, 2015 10:53 pm

Using right-click to select an element in a "list" field

Post by Pierre1234 » Mon Aug 24, 2015 11:34 pm

Hello,
I would like to know how to select an element of a list field using the right click.
Is it possible?
I didn't see any option for that.
May be i could use the messages "mouseUp" or "mouseDown" with button index 3 but in that case, how can i find the item under the mouse location?
Is there a mean to get the item under the mouse pointer?
Regards.

Pierre1234
Posts: 3
Joined: Sat Jun 06, 2015 10:53 pm

Re: Using right-click to select an element in a "list" field

Post by Pierre1234 » Mon Aug 24, 2015 11:55 pm

Hello,

I found it:

on mouseUp
set the hilitedLines of me to word 2 of the clickLine
end mouseUp

Generally, formulate a problem leads to its solution, thanks to the great function clickLine :-)

Klaus
Posts: 14187
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Using right-click to select an element in a "list" field

Post by Klaus » Tue Aug 25, 2015 12:25 pm

Bonjour Pierre,


1. welcome to the forum! :D
Pierre1234 wrote:Generally, formulate a problem leads to its solution, thanks to the great function clickLine :-)
2. Exactement!
And not only this little function, everything actually! :)


Best

Klaus

Post Reply