Class TDraggable

Description

TDraggable is a control which can be dragged

This control will make "draggable" control. Properties :

Ghosting : If set to "Ghosting" or "True", the dragged element will be cloned, and the clone will be dragged. If set to "SuperGhosting", the element will be cloned, and attached to body, so it can be dragged outside of its parent. If set to "None" of "False" (default), the element itself is dragged Revert: Set to True if you want your dragged element to revert to its initial position if not dropped on a valid area. Constraint: Set this to Horizontal or Vertical if you want to constraint your move in one direction. Handle:

  • author: Christophe BOULAIN (Christophe.Boulain@gmail.com)
  • version: $Id: TDraggable.php 3159 2012-06-01 18:01:40Z ctrlaltca $
  • copyright: Copyright © 2008, PradoSoft
  • license: http://www.pradosoft.com/license

Located in /Web/UI/ActiveControls/TDraggable.php (line 31)

TComponent
   |
   --TApplicationComponent
      |
      --TControl
         |
         --TWebControl
            |
            --TPanel
               |
               --TDraggable
Method Summary
void addAttributesToRender ( $writer)
string getClientClassName ()
CDraggableConstraint getConstraint ()
TDraggableGhostingOption getGhosting ()
string getHandle ()
TDraggableRevertOption getRevert ()
void onPreRender (mixed $param)
void setConstraint (CDraggableConstraint $value)
void setGhosting ( $value)
void setHandle (string $value)
void setRevert (boolean $value)
Variables

Inherited Variables

Inherited from TWebControl

TWebControl::$_decorator
Methods
addAttributesToRender (line 154)

Ensure that the ID attribute is rendered and registers the javascript code for initializing the active control.

  • access: protected
void addAttributesToRender ( $writer)
  • $writer

Redefinition of:
TPanel::addAttributesToRender()
Adds attributes to renderer.
getClientClassName (line 175)

Gets the name of the javascript class responsible for performing postback for this control.

This method overrides the parent implementation.

  • return: the javascript class name
  • access: protected
string getClientClassName ()
getConstraint (line 125)

Determine if the element should be constrainted in one direction or not

  • access: public
CDraggableConstraint getConstraint ()
getGhosting (line 95)

Determine if the element should be cloned when dragged If true, Clones the element and drags the clone, leaving the original in place until the clone is dropped.

Defaults to false Since 3.2, Ghosting can be set to one of the value of TDraggableGhostingOptions enumeration.

  • "True" or "Ghosting" means standard pre-3.2 ghosting mechanism
  • "SuperGhosting" use the Superghosting patch by Christopher Williams, which allow elements to be dragged from an scrollable list
  • "False" or "None" means no Ghosting options

  • return: to clone the element
  • access: public
TDraggableGhostingOption getGhosting ()
getHandle (line 46)

Get the handle id or css class

  • access: public
string getHandle ()
getPostBackOptions (line 184)

Gets the post back options for this textbox.

  • access: protected
array getPostBackOptions ()
getRevert (line 60)

Determine if draggable element should revert to it orginal position upon release in an non-droppable container.

Since 3.2, Revert property can be set to one of the value of TDraggableRevertOption enumeration.

  • 'True' or 'Revert' : The draggable will revert to it's original position
  • 'False' or 'None' : The draggable won't revert to it's original position
  • 'Failure' : The draggable will only revert if it's dropped on a non droppable area

  • return: true to revert
  • access: public
TDraggableRevertOption getRevert ()
onPreRender (line 145)

Registers clientscripts

This method overrides the parent implementation and is invoked before render.

  • access: public
void onPreRender (mixed $param)
  • mixed $param: event parameter

Redefinition of:
TWebControl::onPreRender()
If your subclass overrides the onPreRender method be sure to call this method through parent::onPreRender($param); so your sub-class can be decorated, among other things.
setConstraint (line 134)

Set wether the element should be constrainted in one direction

  • access: public
void setConstraint (CDraggableConstraint $value)
  • CDraggableConstraint $value
setGhosting (line 112)

Sets wether the element should be cloned when dragged If true, Clones the element and drags the clone, leaving the original in place until the clone is dropped.

Defaults to false

Since 3.2, Ghosting can be set to one of the value of TDraggableGhostingOptions enumeration.

  • "True" or "Ghosting" means standard pre-3.2 ghosting mechanism
  • "SuperGhosting" use the Superghosting patch by Christopher Williams, which allow elements to be dragged from an scrollable list
  • "False" or "None" means no Ghosting options

  • access: public
void setGhosting ( $value)
  • $value
setHandle (line 37)

Set the handle id or css class

  • access: public
void setHandle (string $value)
  • string $value
setRevert (line 74)

Sets whether the draggable element should revert to it orginal position upon release in an non-droppable container.

Since 3.2, Revert property can be set to one of the value of TDraggableRevertOption enumeration.

  • 'True' or 'Revert' : The draggable will revert to it's original position
  • 'False' or 'None' : The draggable won't revert to it's original position
  • 'Failure' : The draggable will only revert if it's dropped on a non droppable area

  • access: public
void setRevert (boolean $value)
  • boolean $value: true to revert

Inherited Methods

Inherited From TPanel

TPanel::addAttributesToRender()
TPanel::createStyle()
TPanel::getBackImageUrl()
TPanel::getDefaultButton()
TPanel::getDirection()
TPanel::getGroupingText()
TPanel::getHorizontalAlign()
TPanel::getScrollBars()
TPanel::getTagName()
TPanel::getWrap()
TPanel::render()
TPanel::renderBeginTag()
TPanel::renderEndTag()
TPanel::setBackImageUrl()
TPanel::setDefaultButton()
TPanel::setDirection()
TPanel::setGroupingText()
TPanel::setHorizontalAlign()
TPanel::setScrollBars()
TPanel::setWrap()

Inherited From TWebControl

TWebControl::addAttributesToRender()
TWebControl::clearStyle()
TWebControl::copyBaseAttributes()
TWebControl::createStyle()
TWebControl::getAccessKey()
TWebControl::getBackColor()
TWebControl::getBorderColor()
TWebControl::getBorderStyle()
TWebControl::getBorderWidth()
TWebControl::getCssClass()
TWebControl::getDecorator()
TWebControl::getDisplay()
TWebControl::getEnsureId()
TWebControl::getFont()
TWebControl::getForeColor()
TWebControl::getHasStyle()
TWebControl::getHeight()
TWebControl::getStyle()
TWebControl::getTabIndex()
TWebControl::getTagName()
TWebControl::getToolTip()
TWebControl::getWidth()
TWebControl::onPreRender()
TWebControl::render()
TWebControl::renderBeginTag()
TWebControl::renderContents()
TWebControl::renderEndTag()
TWebControl::setAccessKey()
TWebControl::setBackColor()
TWebControl::setBorderColor()
TWebControl::setBorderStyle()
TWebControl::setBorderWidth()
TWebControl::setCssClass()
TWebControl::setDisplay()
TWebControl::setEnsureId()
TWebControl::setForeColor()
TWebControl::setHeight()
TWebControl::setStyle()
TWebControl::setTabIndex()
TWebControl::setToolTip()
TWebControl::setWidth()

Inherited From TControl

TControl::__construct()
TControl::addedControl()
TControl::addParsedObject()
TControl::addToPostDataLoader()
TControl::applyStyleSheetSkin()
TControl::autoBindProperty()
TControl::autoDataBindProperties()
TControl::bindProperty()
TControl::broadcastEvent()
TControl::bubbleEvent()
TControl::clearChildState()
TControl::clearControlState()
TControl::clearNamingContainer()
TControl::clearViewState()
TControl::convertUniqueIdToClientId()
TControl::createChildControls()
TControl::createControlCollection()
TControl::dataBind()
TControl::dataBindChildren()
TControl::dataBindProperties()
TControl::ensureChildControls()
TControl::findControl()
TControl::findControlsByID()
TControl::findControlsByType()
TControl::focus()
TControl::getAdapter()
TControl::getAllowChildControls()
TControl::getAttribute()
TControl::getAttributes()
TControl::getChildControlsCreated()
TControl::getClientID()
TControl::getControls()
TControl::getControlStage()
TControl::getControlState()
TControl::getCustomData()
TControl::getEnabled()
TControl::getEnableTheming()
TControl::getEnableViewState()
TControl::getHasAdapter()
TControl::getHasAttributes()
TControl::getHasChildInitialized()
TControl::getHasControls()
TControl::getHasInitialized()
TControl::getHasLoaded()
TControl::getHasLoadedPostData()
TControl::getHasPreRendered()
TControl::getID()
TControl::getIsSkinApplied()
TControl::getNamingContainer()
TControl::getPage()
TControl::getParent()
TControl::getRegisteredObject()
TControl::getSkinID()
TControl::getSourceTemplateControl()
TControl::getTemplateControl()
TControl::getUniqueID()
TControl::getViewState()
TControl::getVisible()
TControl::hasAttribute()
TControl::initRecursive()
TControl::isDescendentOf()
TControl::isObjectRegistered()
TControl::loadRecursive()
TControl::loadState()
TControl::loadStateRecursive()
TControl::onDataBinding()
TControl::onInit()
TControl::onLoad()
TControl::onPreRender()
TControl::onUnload()
TControl::preRenderRecursive()
TControl::raiseBubbleEvent()
TControl::registerObject()
TControl::removeAttribute()
TControl::removedControl()
TControl::render()
TControl::renderChildren()
TControl::renderControl()
TControl::saveState()
TControl::saveStateRecursive()
TControl::setAdapter()
TControl::setAttribute()
TControl::setChildControlsCreated()
TControl::setControlStage()
TControl::setControlState()
TControl::setCustomData()
TControl::setEnabled()
TControl::setEnableTheming()
TControl::setEnableViewState()
TControl::setID()
TControl::setPage()
TControl::setSkinID()
TControl::setTemplateControl()
TControl::setViewState()
TControl::setVisible()
TControl::trackViewState()
TControl::traverseChildControls()
TControl::unbindProperty()
TControl::unloadRecursive()
TControl::unregisterObject()
TControl::__get()

Inherited From TApplicationComponent

TApplicationComponent::getApplication()
TApplicationComponent::getRequest()
TApplicationComponent::getResponse()
TApplicationComponent::getService()
TApplicationComponent::getSession()
TApplicationComponent::getUser()
TApplicationComponent::publishAsset()
TApplicationComponent::publishFilePath()

Inherited From TComponent

TComponent::addParsedObject()
TComponent::attachEventHandler()
TComponent::canGetProperty()
TComponent::canSetProperty()
TComponent::createdOnTemplate()
TComponent::detachEventHandler()
TComponent::evaluateExpression()
TComponent::evaluateStatements()
TComponent::getEventHandlers()
TComponent::getSubProperty()
TComponent::hasEvent()
TComponent::hasEventHandler()
TComponent::hasProperty()
TComponent::raiseEvent()
TComponent::setSubProperty()
TComponent::__call()
TComponent::__get()
TComponent::__set()
TComponent::__sleep()
TComponent::__wakeup()
Class Constants

Documentation generated on Mon, 25 Jun 2012 14:38:03 +0200 by phpDocumentor 1.4.3