I’m building a flash app that has some draggable buttons on it and I want them to behave like this:
- You click on it, ClickEvent1 happens,
- You click and hold on the button, you
can move it. If you release from the
hold, it does NOT trigger the
ClickEvent
I’m running into the logic problem of not knowing whether a user is just clicking or starting a drag event. Does anyone know any logic to get around this issue? I have thought of alternatives such as placing regions of the button that are only draggable or only clickable, but I’ve seen this type of functionality in other flash apps and I’m wondering how it is accomplished.
Another approach could be the interval between mousedown and mouseup – a drag will take longer than a click.