Interface I_CmsDraggable

All Known Subinterfaces:
I_CmsListItem
All Known Implementing Classes:
CmsAttributeValueView, CmsCategoryTreeItem, CmsContainerPageElementPanel, CmsCreatableListItem, CmsGalleryTreeItem, CmsGroupContainerElementPanel, CmsLazyTreeItem, CmsLazyTreeItem.LoadingItem, CmsListItem, CmsMenuListItem, CmsModelPageTreeItem, CmsResultListItem, CmsSimpleListItem, CmsSitemapTreeItem, CmsToolbarClipboardView.CmsClipboardDeletedItem, CmsTreeItem

public interface I_CmsDraggable
Interface defining all methods used by drag and drop on a draggable element.

Since:
8.0.0
  • Method Details

    • getCursorOffsetDelta

      com.google.common.base.Optional<int[]> getCursorOffsetDelta()
      Gets an optional pair of integers which are to be used as an "offset delta" for the drag and drop process.

      Returns:
      an optional array containing exactly 2 entries [x,y]
    • getDragHelper

      com.google.gwt.dom.client.Element getDragHelper(I_CmsDropTarget target)
      Creates the drag helper element and attaches it into the DOM.

      Parameters:
      target - the drop target
      Returns:
      the drag helper element
    • getElement

      com.google.gwt.dom.client.Element getElement()
      Returns the draggable element.

      Returns:
      the element
    • getId

      Returns the draggable id.

      Returns:
      the id
    • getParentTarget

      Returns the parent drop target or null if there is none.

      Returns:
      the parent drop target
    • getPlaceholder

      com.google.gwt.dom.client.Element getPlaceholder(I_CmsDropTarget target)
      Creates the drag placeholder element.

      Parameters:
      target - the drop target
      Returns:
      the drag placeholder element
    • onDragCancel

      void onDragCancel()
      Executed on drag cancel.

    • onDrop

      void onDrop(I_CmsDropTarget target)
      Executed on drop.

      Parameters:
      target - the drop target
    • onStartDrag

      Executed on drag start.

      Parameters:
      target - the current drop target