class type t =Inheritsobject
..end
method scroll : bool Js.t Js.prop
When set to true, the utility automatically tries to scroll the browser window when a drag and drop element is dragged near the viewport boundary.
Defaults to: true
method alignElWithMouse : Dom_html.element Js.t -> Js.number Js.t -> Js.number Js.t -> unit Js.meth
Sets the element to the location of the mousedown or click event, maintaining the cursor location relative to the location on the element that was clicked. Override this if you want to place the element in a location other than where the cursor is.
Parameters:
Dom_html.element Js.t
the element to move
Js.number Js.t
the X coordinate of the mousedown or drag event
Js.number Js.t
the Y coordinate of the mousedown or drag event
method applyConfig : unit Js.meth
Sets up config options specific to this class. Overrides Ext.dd.DragDrop, but all versions of this method through the inheritance chain are called
method autoOffset : Js.number Js.t -> Js.number Js.t -> unit Js.meth
Sets the pointer offset to the distance between the linked element's top left corner and the location the element was clicked.
Parameters:
Js.number Js.t
the X coordinate of the click
Js.number Js.t
the Y coordinate of the click
method b4Drag : 'a. 'a Js.t -> unit Js.meth
method b4MouseDown : 'b. 'b Js.t -> unit Js.meth
method cachePosition : Js.number Js.t Js.optdef -> Js.number Js.t Js.optdef -> unit Js.meth
Saves the most recent position so that we can reset the constraints and tick marks on-demand. We need to know this so that we can calculate the number of pixels the element is offset from its original position.
Parameters:
Js.number Js.t
(optional)
the current x position (this just makes it so we don't have to look it up again)
Js.number Js.t
(optional)
the current y position (this just makes it so we don't have to look it up again)
method setDelta : Js.number Js.t -> Js.number Js.t -> unit Js.meth
Sets the pointer offset. You can call this directly to force the offset to be in a particular location (e.g., pass in 0,0 to set it to the center of the object)
Parameters:
Js.number Js.t
the distance from the left
Js.number Js.t
the distance from the top
method setDragElPos : Js.number Js.t -> Js.number Js.t -> unit Js.meth
Sets the drag element to the location of the mousedown or click event, maintaining the cursor location relative to the location on the element that was clicked. Override this if you want to place the element in a location other than where the cursor is.
Parameters:
Js.number Js.t
the X coordinate of the mousedown or drag event
Js.number Js.t
the Y coordinate of the mousedown or drag event
method toString : Js.js_string Js.t Js.meth
toString method
Returns:
Js.js_string Js.t
string representation of the dd obj