Class type Goog.Fx.abstractDragDrop
class type abstractDragDrop = object..end
Inherits
method addItem : dragDropItem Js.t -> unit Js.meth
Add item to drag object.
method addScrollableContainer :
'a. (#Dom_html.element as 'a) Js.t -> unit Js.meth
Makes drag and drop aware of a target container that could scroll mid drag.
method addTarget : abstractDragDrop Js.t -> unit Js.meth
Associate drop target with drag element.
method createDragElement :
'b. (#Dom_html.element as 'b) Js.t -> Dom_html.element Js.t Js.meth
Creates an element for the item being dragged.
Returns The new drag element.
method disposeInternal : unit Js.meth
method endDrag : dragEvent Js.t -> unit Js.meth
Event handler that's used to stop drag. Fires a drop event if over a valid target.
method getDragElementPosition :
'c 'd.
(#Dom_html.element as 'c) Js.t ->
(#Dom_html.element as 'd) Js.t ->
Goog.Events.browserEvent Js.t -> Goog.Math.coordinate Js.t Js.meth
Returns the position for the drag element.
Returns The position for the drag element.
method getDragger : dragger Js.t Js.meth
Returns the dragger object.
Returns The dragger object used by this drag and drop
instance.
method init : unit Js.meth
Initialize drag and drop functionality for sources/targets already added. Sources/targets added after init has been called will initialize themselves one by one.
method isInitialized : bool Js.t Js.meth
Whether the control has been initialized.
Returns True if it's been initialized.
method maybeStartDrag :
Goog.Events.browserEvent Js.t -> dragDropItem Js.t -> unit Js.meth
Starts a drag event for an item if the mouse button stays pressed and the cursor moves a few pixels. Allows dragging of items without first having to register them with addItem.
method recalculateDragTargets : unit Js.meth
Recalculates the geometry of this source's drag targets. Call this if the position or visibility of a drag target has changed during a drag, or if targets are added or removed.
TODO(user): this is an expensive operation; more efficient APIs may be necessary.
method removeItems : unit Js.meth
Removes all items.
method setDragClass : Js.js_string Js.t -> unit Js.meth
Set class to add to source elements being dragged.
method setScrollTarget :
'e. (#Dom_html.eventTarget as 'e) Js.t -> unit Js.meth
Sets the SCROLL event target to make drag element follow scrolling.
method setSourceClass : Js.js_string Js.t -> unit Js.meth
Set class to add to source elements.
method setTargetClass : Js.js_string Js.t -> unit Js.meth
Set class to add to target elements.
method startDrag :
Goog.Events.browserEvent Js.t -> dragDropItem Js.t -> unit Js.meth
Event handler that's used to start drag.
