event.drag: selectable function is called too early

14 views
Skip to first unread message

Sahab Yazdani

unread,
May 6, 2010, 4:09:30 PM5/6/10
to threedubmedia
The event.drag library contains a function called "selectable" which
disables the selection rectangle in IE/FF (and possibly others...)
when you start the drag operation which is great. The problem is that
it gets called too early. If you look example #4 in on the demo page
(http://threedubmedia.com/demo/drag/), you'll see what I am talking
about.

On that example, you can't highlight the text "#demo4_box" because the
selectable method disables the selection on the entire div, whereas
the user of the library is restricting the drag to the '.handle' class
in the ondragstart event handler.

This can probably be worked around by undoing whatever selectable is
doing in the ondragstart event handler, but perhaps 3wme can think of
a way of calling selectable *after* the ondragstart event has gone
through?

Thanks for the great plug-in by the way. Very powerful.

--
You received this message because you are subscribed to the Google Groups "threedubmedia" group.
To post to this group, send email to threed...@googlegroups.com.
To unsubscribe from this group, send email to threedubmedi...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/threedubmedia?hl=en.

3wme

unread,
May 6, 2010, 4:47:31 PM5/6/10
to threedubmedia
This should be fixed in the new version, coming soon.

Sahab Yazdani

unread,
May 6, 2010, 5:01:30 PM5/6/10
to threedubmedia
I know as developers we hate this question, but I have to ask: do you
have an ETA? and also, can you tell us about some of the
characteristics of the new version? (is the API compatible with the
existing version, etc.)

Thank you kindly,

3wme

unread,
May 6, 2010, 5:27:52 PM5/6/10
to threedubmedia
The 2.0 versions are code complete, still fixing some minor bugs and
testing cross browser. ETA is most likely about four weeks (early
June). I still need to complete testing and documentation.

The API is the same, everything is still event driven, there are new
custom event properties and to differentiate from normal event
properties, I am trying to keep them together in a single "drag"
property of the event object. For example, instead of "event.offsetX"
you would write "event.drag.offsetX" I will also include a patch that
copies the currently supported event properties back up to the event
object, for backwards compatibility.

New Features:

- New "drag" option for handles
- New "drag" options for drop targets
- New "draginit" and "dropinit" events
- Special events are configured for all event types (You are not
forced to bind a "drag" or "drop" event)
- Drop targets can be managed automatically when dragging begins
- New event properties (startX, startY, originalX, originalY, deltaX,
deltaY)
- Improved text selection disabling
- Support for simultaneous multiple "drag" events
- Support for simultaneous multiple "drop" events
- Support for "live" drag events
- Support for "live" drop events

I hope some of these features help get you excited.
Reply all
Reply to author
Forward
0 new messages