Roo.util.Observable Roo.dd.DragDrop Roo.dd.DD Roo.dd.DDProxy Roo.dd.DragSource Roo.dd.DragZone
Package: | Roo.dd |
Defined In: | Roo/dd/DragZone.js. |
Class: | DragZone |
Extends: | Roo.dd.DragSource |
Options | Defined By | |
---|---|---|
containerScroll : Boolean
True to register this container with the Scrollmanager
for auto scrolling during drag operations.
True to register this container with the Scrollmanager
for auto scrolling during drag operations. |
Roo.dd.DragZone | |
dropAllowed : String
The CSS class returned to the drag source when drop is allowed (defaults to "x-dd-drop-ok").
The CSS class returned to the drag source when drop is allowed (defaults to "x-dd-drop-ok").
|
Roo.dd.DragSource | |
dropNotAllowed : String
The CSS class returned to the drag source when drop is not allowed (defaults to "x-dd-drop-nodrop").
The CSS class returned to the drag source when drop is not allowed (defaults to "x-dd-drop-nodrop").
|
Roo.dd.DragSource | |
hlColor : String
The color to use when visually highlighting the drag source in the afterRepair
method after a failed drop (defaults to "c3daf9" - light blue)
The color to use when visually highlighting the drag source in the afterRepair
method after a failed drop (defaults to "c3daf9" - light blue) |
Roo.dd.DragZone | |
listeners : Object
list of events and functions to call for this object,
For example :
list of events and functions to call for this object,
For example :
|
Roo.util.Observable |
Property | Description | Defined By | |
---|---|---|---|
Roo.dd.DragZone.dragElId :
String
|
The default drag frame div id
The default drag frame div id
|
Roo.dd.DDProxy |
Method | Defined By | |
---|---|---|
addEvents
(Object object)
Used to define events on this Observable
Used to define events on this Observable
|
Roo.util.Observable | |
addInvalidHandleClass
(string cssClass)
Lets you specify a css class of elements that will not initiate a drag
Lets you specify a css class of elements that will not initiate a drag
|
Roo.dd.DragDrop | |
addInvalidHandleId
(string id)
Lets you to specify an element id for a child of a drag handle
that should not initiate a drag
Lets you to specify an element id for a child of a drag handle
that should not initiate a drag
|
Roo.dd.DragDrop | |
addInvalidHandleType
(string tagName)
Allows you to specify a tag name that should not start a drag operation
when clicked.
Allows you to specify a tag name that should not start a drag operation
when clicked. This is designed to facilitate embedding links within a drag handle that do something other than start the drag.
|
Roo.dd.DragDrop | |
Appends an event handler to this component
Appends an event handler to this component
|
Roo.util.Observable | |
addToGroup
(sGroup)
Add this instance to a group of related drag/drop objects.
Add this instance to a group of related drag/drop objects. All
instances belong to at least one group, and can belong to as many groups as needed.
|
Roo.dd.DragDrop | |
afterRepair
()
Called after a repair of an invalid drop.
Called after a repair of an invalid drop. By default, highlights this.dragData.ddel
|
Roo.dd.DragZone | |
alignElWithMouse
(HTMLElement el, int iPageX, int iPageY)
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.
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.
|
Roo.dd.DD | |
applyConfig
()
Applies the configuration parameters that were passed into the constructor.
Applies the configuration parameters that were passed into the constructor.
This is supposed to happen at each level through the inheritance chain. So a DDProxy implentation will execute apply config on DDProxy, DD, and DragDrop in order to get all of the parameters that are available in each object. |
Roo.dd.DragDrop | |
autoOffset
(int iPageX, int iPageY)
Sets the pointer offset to the distance between the linked element's top
left corner and the location the element was clicked
Sets the pointer offset to the distance between the linked element's top
left corner and the location the element was clicked
|
Roo.dd.DD | |
An empty function by default, but provided so that you can perform a custom action before the dragged
item is dropped onto the target and optionally cancel the onDragDrop.
An empty function by default, but provided so that you can perform a custom action before the dragged
item is dropped onto the target and optionally cancel the onDragDrop.
|
Roo.dd.DragSource | |
An empty function by default, but provided so that you can perform a custom action
before the dragged item enters the drop target and optionally cancel the onDragEnter.
An empty function by default, but provided so that you can perform a custom action
before the dragged item enters the drop target and optionally cancel the onDragEnter.
|
Roo.dd.DragSource | |
An empty function by default, but provided so that you can perform a custom action before the dragged
item is dragged out of the target without dropping, and optionally cancel the onDragOut.
An empty function by default, but provided so that you can perform a custom action before the dragged
item is dragged out of the target without dropping, and optionally cancel the onDragOut.
|
Roo.dd.DragSource | |
An empty function by default, but provided so that you can perform a custom action
while the dragged item is over the drop target and optionally cancel the onDragOver.
An empty function by default, but provided so that you can perform a custom action
while the dragged item is over the drop target and optionally cancel the onDragOver.
|
Roo.dd.DragSource | |
An empty function by default, but provided so that you can perform a custom action after an invalid
drop has occurred.
An empty function by default, but provided so that you can perform a custom action after an invalid
drop has occurred.
|
Roo.dd.DragSource | |
cachePosition
(iPageX, iPageY)
Saves the most recent position so that we can reset the constraints and
tick marks on-demand.
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.
|
Roo.dd.DD | |
clearConstraints
()
Clears any constraints applied to this instance.
Clears any constraints applied to this instance. Also clears ticks
since they can't exist independent of a constraint at this time. |
Roo.dd.DragDrop | |
clearTicks
()
Clears any tick interval defined for this instance
Clears any tick interval defined for this instance
|
Roo.dd.DragDrop | |
createFrame
()
Creates the proxy element if it does not yet exist
Creates the proxy element if it does not yet exist
|
Roo.dd.DDProxy | |
endDrag
(Event e)
Fired when we are done dragging the object
Fired when we are done dragging the object
|
Roo.dd.DragDrop | |
Fires the specified event with the passed parameters (minus the event name).
|
Roo.util.Observable | |
function toString() {
[native code]
}
()
:
string
toString method
toString method
|
Roo.dd.DragDrop | |
getDragData
(EventObject e)
:
Object
Called when a mousedown occurs in this container.
Called when a mousedown occurs in this container. Looks in {link Roo.dd.Registry}
for a valid target to drag based on the mouse down. Override this method to provide your own lookup logic (e.g. finding a child by class name). Make sure your returned object has a "ddel" attribute (with an HTML Element) for other functions to work.
|
Roo.dd.DragZone | |
getDragEl
()
:
HTMLElement
Returns a reference to the actual element to drag.
Returns a reference to the actual element to drag. By default this is
the same as the html element, but it can be assigned to another element. An example of this can be found in Roo.dd.DDProxy
|
Roo.dd.DragDrop | |
getEl
()
:
HTMLElement
Returns a reference to the linked element
Returns a reference to the linked element
|
Roo.dd.DragDrop | |
getProxy
()
:
Roo.dd.StatusProxy
Returns the drag source's underlying {link Roo.dd.StatusProxy}
Returns the drag source's underlying {link Roo.dd.StatusProxy}
|
Roo.dd.DragSource | |
getRepairXY
(EventObject e)
:
Array
Called before a repair of an invalid drop to get the XY to animate to.
Called before a repair of an invalid drop to get the XY to animate to. By default returns
the XY of this.dragData.ddel
|
Roo.dd.DragZone | |
Roo.util.Observable | ||
hideProxy
()
Hides the drag source's {link Roo.dd.StatusProxy}
Hides the drag source's {link Roo.dd.StatusProxy}
|
Roo.dd.DragSource | |
init
(id, String sGroup, object config)
Sets up the DragDrop object.
Sets up the DragDrop object. Must be called in the constructor of any
Roo.dd.DragDrop subclass
|
Roo.dd.DragDrop | |
initFrame
()
Initialization for the drag frame element.
Initialization for the drag frame element. Must be called in the
constructor of all subclasses |
Roo.dd.DDProxy | |
initTarget
(id, String sGroup, object config)
Initializes Targeting functionality only.
Initializes Targeting functionality only... the object does not
get a mousedown handler.
|
Roo.dd.DragDrop | |
isLocked
()
:
boolean
Returns true if this instance is locked, or the drag drop mgr is locked
(meaning that all drag/drop is disabled on the page.
Returns true if this instance is locked, or the drag drop mgr is locked
(meaning that all drag/drop is disabled on the page.)
|
Roo.dd.DragDrop | |
isTarget
()
By default, all insances can be a drop target.
By default, all insances can be a drop target. This can be disabled by
setting isTarget to false. |
Roo.dd.DragDrop | |
isValidHandleChild
(HTMLElement node)
:
boolean
Checks the tag exclusion list to see if this click should be ignored
Checks the tag exclusion list to see if this click should be ignored
|
Roo.dd.DragDrop | |
lock
()
Lock this instance
Lock this instance
|
Roo.dd.DragDrop | |
Appends an event handler to this element (shorthand for addListener)
Appends an event handler to this element (shorthand for addListener)
|
Roo.util.Observable | |
onAvailable
()
Override the onAvailable method to do what is needed after the initial
position was determined.
Override the onAvailable method to do what is needed after the initial
position was determined. |
Roo.dd.DragDrop | |
An empty function by default, but provided so that you can perform a custom action before the initial
drag event begins and optionally cancel it.
An empty function by default, but provided so that you can perform a custom action before the initial
drag event begins and optionally cancel it.
|
Roo.dd.DragSource | |
onDrag
(Event e)
Abstract method called during the onMouseMove event while dragging an
object.
Abstract method called during the onMouseMove event while dragging an
object.
|
Roo.dd.DragDrop | |
onDragDrop
(Event e, String|DragDrop[] id)
Abstract method called when this item is dropped on another DragDrop
obj
Abstract method called when this item is dropped on another DragDrop
obj
|
Roo.dd.DragDrop | |
onDragEnter
(Event e, String|DragDrop[] id)
Abstract method called when this element fist begins hovering over
another DragDrop obj
Abstract method called when this element fist begins hovering over
another DragDrop obj
|
Roo.dd.DragDrop | |
onDragOut
(Event e, String|DragDrop[] id)
Abstract method called when we are no longer hovering over an element
Abstract method called when we are no longer hovering over an element
|
Roo.dd.DragDrop | |
onDragOver
(Event e, String|DragDrop[] id)
Abstract method called when this element is hovering over another
DragDrop obj
Abstract method called when this element is hovering over another
DragDrop obj
|
Roo.dd.DragDrop | |
Called once drag threshold has been reached to initialize the proxy element.
Called once drag threshold has been reached to initialize the proxy element. By default, it clones the
this.dragData.ddel
|
Roo.dd.DragZone | |
onInvalidDrop
(Event e)
Abstract method called when this item is dropped on an area with no
drop target
Abstract method called when this item is dropped on an area with no
drop target
|
Roo.dd.DragDrop | |
onMouseDown
(Event e)
Event handler that fires when a drag/drop obj gets a mousedown
Event handler that fires when a drag/drop obj gets a mousedown
|
Roo.dd.DragDrop | |
onMouseUp
(Event e)
Event handler that fires when a drag/drop obj gets a mouseup
Event handler that fires when a drag/drop obj gets a mouseup
|
Roo.dd.DragDrop | |
An empty function by default, but provided so that you can perform a custom action once the initial
drag event has begun. |
Roo.dd.DragSource | |
padding
()
The padding configured for this drag and drop object for calculating
the drop zone intersection with this object.
The padding configured for this drag and drop object for calculating
the drop zone intersection with this object. |
Roo.dd.DragDrop | |
purgeListeners
()
Removes all listeners for this object
Removes all listeners for this object
|
Roo.util.Observable | |
removeFromGroup
(string sGroup)
Remove's this instance from the supplied interaction group
Remove's this instance from the supplied interaction group
|
Roo.dd.DragDrop | |
removeInvalidHandleClass
(string cssClass)
Unsets an invalid css class
Unsets an invalid css class
|
Roo.dd.DragDrop | |
removeInvalidHandleId
(string id)
Unsets an invalid handle id
Unsets an invalid handle id
|
Roo.dd.DragDrop | |
removeInvalidHandleType
(string tagName)
Unsets an excluded tag name set by addInvalidHandleType
Unsets an excluded tag name set by addInvalidHandleType
|
Roo.dd.DragDrop | |
Roo.util.Observable | ||
resetConstraints
(boolean maintainOffset)
resetConstraints must be called if you manually reposition a dd element.
resetConstraints must be called if you manually reposition a dd element.
|
Roo.dd.DragDrop | |
setDelta
(int iDeltaX, int iDeltaY)
Sets the pointer offset.
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)
|
Roo.dd.DD | |
setDragElId
(id)
Allows you to specify that an element other than the linked element
will be moved with the cursor during a drag
Allows you to specify that an element other than the linked element
will be moved with the cursor during a drag
|
Roo.dd.DragDrop | |
setDragElPos
(int iPageX, int iPageY)
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.
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.
|
Roo.dd.DD | |
setHandleElId
(id)
Allows you to specify a child of the linked element that should be
used to initiate the drag operation.
Allows you to specify a child of the linked element that should be
used to initiate the drag operation. An example of this would be if you have a content div with text and links. Clicking anywhere in the content area would normally start the drag operation. Use this method to specify that an element inside of the content div is the element that starts the drag operation.
|
Roo.dd.DragDrop | |
setInitPosition
(int diffX, int diffY)
Stores the initial placement of the linked element.
Stores the initial placement of the linked element.
|
Roo.dd.DragDrop | |
setOuterHandleElId
(id)
Allows you to set an element outside of the linked element as a drag
handle
Allows you to set an element outside of the linked element as a drag
handle
|
Roo.dd.DragDrop | |
setPadding
(int iTop, int iRight, int iBot, int iLeft)
Configures the padding for the target zone in px.
Configures the padding for the target zone in px. Effectively expands
(or reduces) the virtual object size for targeting calculations. Supports css-style shorthand; if only one parameter is passed, all sides will have that padding, and if only two are passed, the top and bottom will have the first param, the left and right the second.
|
Roo.dd.DragDrop | |
setXConstraint
(int iLeft, int iRight, int iTickSize)
By default, the element can be dragged any place on the screen.
By default, the element can be dragged any place on the screen. Use
this method to limit the horizontal travel of the element. Pass in 0,0 for the parameters if you want to lock the drag to the y axis.
|
Roo.dd.DragDrop | |
setYConstraint
(int iUp, int iDown, int iTickSize)
By default, the element can be dragged any place on the screen.
By default, the element can be dragged any place on the screen. Set
this to limit the vertical travel of the element. Pass in 0,0 for the parameters if you want to lock the drag to the x axis.
|
Roo.dd.DragDrop | |
startDrag
(int X, int Y)
Abstract method called after a drag/drop object is clicked
and the drag or mousedown time thresholds have beeen met.
Abstract method called after a drag/drop object is clicked
and the drag or mousedown time thresholds have beeen met.
|
Roo.dd.DragDrop | |
Roo.util.Observable | ||
unlock
()
Unlock this instace
Unlock this instace
|
Roo.dd.DragDrop | |
unreg
()
Remove all drag and drop hooks for this element
Remove all drag and drop hooks for this element
|
Roo.dd.DragDrop |