I have a button that can be dragged or clicked (with a simple click, like "mouseUp").
The problem is that these two actions interfere with each other. Something like that:
Code: Select all
on mouseDown
if it is a "real" drag then
-- prepare the drag action, with for example changing the icon of the button...
grab me // drag end will be handled by mouseUp
else
-- perform the "real" click action
end if
end mouseDown
on mouseUp
if it was a drag action then
-- do the drag end process
else
-- do the "real" click action
end if
end mouseUp
Thank you for your help.