Namespace: gestures

qui.utils.gestures

Methods

(static) disableDragging(element)

Disable previously configured dragging support on an HTML element.

Parameters:
Name Type Description
element jQuery

the dragged element

Source:

(static) enableDragging(element, onMove, onBegin, onEnd, directionopt, nullable)

Setup an HTML element for dragging.

Parameters:
Name Type Attributes Description
element jQuery

the dragged element

onMove qui.utils.gestures.DragMoveCallback
onBegin qui.utils.gestures.DragBeginCallback
onEnd qui.utils.gestures.DragEndCallback
direction String <optional>
<nullable>

indicates dragging direction: "x", "y" or null for both; defaults to null

Source:

Type Definitions

DragBeginCallback(elemX, elemY, pageX, pageY) → {Boolean}

Drag Begin Callback Function.

Parameters:
Name Type Description
elemX Number

the initial element x coordinate, relative to page

elemY Number

the initial element y coordinate, relative to page

pageX Number

the x coordinate, relative to page

pageY Number

the y coordinate, relative to page

Source:
Returns:

false to prevent dragging

Type
Boolean

DragEndCallback(elemX, elemY, deltaX, deltaY, pageX, pageY)

Drag End Callback Function.

Parameters:
Name Type Description
elemX Number

the final element x coordinate, relative to page

elemY Number

the final element y coordinate, relative to page

deltaX Number

the final x coordinate variation, relative to initial drag point

deltaY Number

the final y coordinate variation, relative to initial drag point

pageX Number

the x coordinate inside, relative to page

pageY Number

the y coordinate inside, relative to page

Source:

DragMoveCallback(elemX, elemY, deltaX, deltaY, pageX, pageY)

Drag Move Callback Function.

Parameters:
Name Type Description
elemX Number

the new element x coordinate, relative to page

elemY Number

the new element y coordinate, relative to page

deltaX Number

the x coordinate variation, relative to initial drag point

deltaY Number

the y coordinate variation, relative to initial drag point

pageX Number

the x coordinate, relative to page

pageY Number

the y coordinate, relative to page

Source: