Results 1 to 2 of 2

Thread: DataView drag and drop strange behavior

  1. #1
    Sencha Premium Member
    Join Date
    Oct 2014
    Posts
    2

    Default DataView drag and drop strange behavior

    I'm currently implementing drag and drop functionality for a DataView, but I'm seeing some strange behavior. I can't drag an item above its initial y-axis value. Also, upon first drag of an item, the element jumps down below my mouse pointer (yet is attached and dragable). I'm using the Ext.dd.DD class with an example below:

    https://fiddle.sencha.com/#fiddle/reo

    I have also tried using the Ext.dd.DragZone, and that seems to work fine, but it doesn't have the desired behavior of actually moving the element in the list of items, since I actually want to re-order items within the DataView. Instead, it creates a proxy element, which is the behavior that I want when I drag-cross view and drop into another DataView.

    Any help would be great.

  2. #2
    Sencha User
    Join Date
    Dec 2007
    Posts
    11
    Answers
    1

    Default

    Hi Andrew,

    a little bit late, but if you inspect the css properties of your dragged item, you can see that the position attribute is either set to nothing or something behaves like inherited. What you need to apply is the property 'absolute' to your actually being dragged element. So simply adjust, implement the b4StartDrag function of your overrides to set this.el.dom.style.position = 'absolute' to achieve the desired behaviour that you can drag the element around.

    See here : https://fiddle.sencha.com/#fiddle/1j1m

Similar Threads

  1. Ext 3.4.0 tree strange Drag and Drop behavior.
    By thyr0ne in forum Ext 3.x: Help & Discussion
    Replies: 2
    Last Post: 9 Jan 2013, 3:13 PM
  2. [FIXED] Strange behavior of DataView in PR3
    By Donbydon in forum Sencha Touch 2.x: Bugs
    Replies: 4
    Last Post: 14 Dec 2011, 8:42 PM
  3. [OPEN-EXTJSIV-293] Strange behavior on window drag
    By c2c-guinness in forum Ext:Bugs
    Replies: 1
    Last Post: 23 Mar 2011, 3:14 PM
  4. Drag&Drop: strange behavior
    By [email protected] in forum Sencha Ext JS Q&A
    Replies: 0
    Last Post: 13 Oct 2009, 10:29 AM
  5. [Ext 2.2.1] Dataview example : Strange behavior in FF
    By vmorale4 in forum Community Discussion
    Replies: 1
    Last Post: 6 Feb 2009, 1:52 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •