Skip to main content

Search and Top Navigation

#7068 closed enhancement (wontfix)

Opened March 04, 2011 11:06PM UTC

Closed March 07, 2011 01:32PM UTC

draggables start and stop events should still fire when no dragging has occurred

Reported by: kellyselden Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.draggable Version: 1.8.10
Keywords: Cc:
Blocked by: Blocking:

i want to perform an action based on if the draggable was clicked but not dragged (ie. deselect).

start: function() { dragged = false },
drag: function() { dragged = true },
stop: function() {
    if (!dragged) {

the obvious workaround is to monitor your own mouse events, but it seems to me that it should work like this. i realize this will probably break a lot of people's code so i won't be surprised if this is wont-fixed ha.

Attachments (0)
Change History (1)

Changed March 07, 2011 01:32PM UTC by scottgonzalez comment:1

resolution: → wontfix
status: newclosed

Draggable is intentionally meant to ignore clicks. Click events should only occur if the element was not dragged. Note that you must not bind your click handler until after you make the element draggable (of set your click handler at least one level higher in the DOM).