Warning: Use of undefined constant Symbol - assumed 'Symbol' (this will throw an Error in a future version of PHP) in /mnt/new-ebs/workbench-106550/lib/dojo/util/docscripts/lib/parser2/dojo2.inc on line 215 Warning: Use of undefined constant JavaScriptSymbol - assumed 'JavaScriptSymbol' (this will throw an Error in a future version of PHP) in /mnt/new-ebs/workbench-106550/lib/dojo/util/docscripts/lib/parser2/dojo2.inc on line 215

dojox/mdnd/dropMode/DefaultDropMode.js

  • Provides:

    • dojox.mdnd.dropMode.DefaultDropMode
  • Requires:

    • dojox.mdnd.AreaManager in common
  • dojox.mdnd.dropMode.DefaultDropMode

    • type
      Function
    • summary
      Enabled a type of calcul for Dnd.
      Default class to find the nearest target.
  • dojox.mdnd.dropMode.DefaultDropMode._oldXPoint

    • type
      Integer
    • summary
      used to save a X position
  • dojox.mdnd.dropMode.DefaultDropMode._oldYPoint

    • type
      Integer
    • summary
      used to save a Y position
  • dojox.mdnd.dropMode.DefaultDropMode._oldBehaviour

    • type
      String
    • summary
      see <getDragPoint>
  • dojox.mdnd.dropMode.DefaultDropMode.addArea

    • parameters:
      • areas: (typeof Array)
        array of areas
      • object: (typeof Object)
        data type of a DndArea
    • returns
      Array
    • summary
      Add a DnD Area into an array sorting by the x position.
    • return_summary
      a sorted area
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode.updateAreas

    • parameters:
      • areaList: (typeof Array)
        array of areas
    • summary
      Refresh intervals between areas to determinate the nearest area to drop an item.
      Algorithm :
      the marker should be the vertical line passing by the
      central point between two contiguous areas.
      Note:
      If the page has only one targetArea, it's not necessary to calculate coords.
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode._updateArea

    • parameters:
      • area: (typeof Object)
        the DnD area
    • summary
      update the DnD area object (i.e. update coordinates of its DOM node)
    • tags:
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode.initItems

    • parameters:
      • area: (typeof Object)
        the DnD area
    • summary
      initialize the horizontal line in order to determinate the drop zone.
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode.refreshItems

    • parameters:
      • area: (typeof Object)
        a DnD area object
      • indexItem: (typeof Integer)
        index of a draggable item
      • size: (typeof Object)
        dropIndicator size
      • added: (typeof Boolean)
        boolean to know if a dropIndicator has been added or deleted
    • summary
      take into account the drop indicator DOM element in order to compute horizontal lines
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode.getDragPoint

    • parameters:
      • coords: (typeof Object)
        an object encapsulating X and Y position
      • size: (typeof Object)
        an object encapsulating width and height values
      • mousePosition: (typeof Object)
        coordinates of mouse
    • summary
      return coordinates of the draggable item
    • description
      return for:
      - X point : the middle
      - Y point : search if the user goes up or goes down with his mouse.
      - Up : top of the draggable item
      - Down : bottom of the draggable item
    • return_summary
      an object of coordinates
      example : {'x':10,'y':10}
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode.getTargetArea

    • parameters:
      • areaList: (typeof Array)
        a list of DnD areas objects
      • coords: (typeof Object)
        coordinates [x,y] of the dragItem
      • currentIndexArea: (typeof integer)
        an index representing the active DnD area
    • returns
      Integer
    • summary
      get the nearest DnD area.
      Coordinates are basically provided by the <getDragPoint> method.
    • return_summary
      the index of the DnD area
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode._checkInterval

    • parameters:
      • areaList: (typeof Array)
        a list of DnD areas objects
      • index: (typeof Integer)
        index of a DnD area (to get the interval)
      • x: (typeof Coord)
        coordinate x, of the dragNode
    • returns
      Boolean
    • summary
      check if the dragNode is in the interval.
      The x coordinate is basically provided by the <getDragPoint> method.
    • return_summary
      true if the dragNode is in intervall
    • tags:
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode.getDropIndex

    • parameters:
      • targetArea: (typeof Object)
        a DnD area object
      • coords: (typeof Object)
        coordinates [x,y] of the draggable item
    • returns
      Integer
    • summary
      Return the index where the drop has to be placed.
    • return_summary
      a number
      or -1 if the area has no children or the drop index represents the last position in to the area
    • type
      Function
  • dojox.mdnd.dropMode.DefaultDropMode.destroy

    • type
      Function
  • dojox.mdnd.dropMode

    • type
      Object
  • dojox.mdnd

    • type
      Object
  • dojox

    • type
      Object