Uploaded image for project: 'Magnolia'
  1. Magnolia
  2. MAGNOLIA-4161

DnD: order node according to move direction

    XMLWordPrintable

Details

    • New Feature
    • Resolution: Fixed
    • Major
    • 4.5
    • None
    • core, page editor
    • None

    Description

      We are now using DnD for moving page elements within an area and the feeling one has is that it kind of implies 'replace the target element with the source element'. With our current impl this only works when moving/dragging elements up or left because, in the end, we always sort the source element before the parent. What we should do is detecting the move/drag direction and react accordingly, namely

      • move up or left -> order source before target
      • move down or right -> order source after target

      This is quite easy to do it in GWT as we have the mouse coordinates for the DragStart and DragEnd events. Attached is quick and dirty code snippet to demonstrate this.

      Checklists

        Acceptance criteria

        Attachments

          Issue Links

            Activity

              People

                fgrilli Federico Grilli
                fgrilli Federico Grilli
                Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: