This repository was archived by the owner on Jul 10, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 21
selectable.drag
Karl edited this page Oct 3, 2018
·
8 revisions
Fires on mousemove / touchmove.
The callback has two parameters which returns the orignal event and coordinates of the selection area (lasso) as an Object.
selectable.on("selectable.drag", function(e, coords) {
});The coords parameter returns an Object of the following format:
{
x1: Number, // the origin x offset
y1: Number, // the origin y offset
x2: Number, // the x offset from x1
y2: Number, // the y offset from y1
}x1,y1 (origin)
+----------------------+
| |
| |
| |
| |
| |
| |
+----------------------+
x2, y2 (mouse pointer)