using the left mousebutton in an unlocked field
Lynch, Jonathan
BNZ2 at CDC.GOV
Fri Mar 18 14:22:05 EST 2005
I just figured out that, while the mousedown handler does not work with
the left button in an unlocked field, one can do much the same thing
using the selectionchanged handler. I think this is very useful.
Like with the following script, which allows for regular left-button
hyperlinking in an unlocked field:
on selectionchanged
if the linktext of the mousecharchunk <> empty then
put the linktext of the mousecharchunk into LT
if exists(card LT) = true then
go card LT
unlock cursor
end if
end if
end selectionchanged
on mousemove
if the mousecharchunk <> empty and the linktext of the mousecharchunk
<> empty then
set the cursor to hand
lock cursor
else
unlock cursor
end if
end mousemove
More information about the use-livecode
mailing list