Opened 11 years ago
Last modified 10 years ago
#8286 open bug
Draggable: Dragged element mouse offset is incorrect when document flow changes
Reported by: | sam | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 2.0.0 |
Component: | ui.draggable | Version: | 1.8.19 |
Keywords: | dbr | Cc: | |
Blocked by: | Blocking: |
Description
If the element's surrounding document flow changes it's position during a drag, the whole drag operation gets messed up. The algorithm is wrong for not considering this to happen (don't argue to me that it's right for behaving like this). A dragged element should always remain under the cursor at the same position during the entire drag operation, regardless of what document changes might effect it's CSS relative positioning.
So, a new algorithm is needed. During drag movement, the element's origin top and origin left should be used to determine how much relative positioning the element needs in order to appear as though it's being dragged by the cursor. Duh.
I hope I'm helping. Maybe I can figure out a detailed algorithm for draggable elements.
Change History (6)
comment:1 Changed 11 years ago by
Summary: | Drag gets fucked up when document flow changes → Drag gets messed up when document flow changes |
---|
comment:2 Changed 10 years ago by
Milestone: | 1.9.0 → 2.0.0 |
---|
comment:3 Changed 10 years ago by
Status: | new → open |
---|
comment:4 Changed 10 years ago by
Okay, thank you. I didn't mean to be rude... Sooooooooooooorrrryyyyy!
comment:5 Changed 10 years ago by
Keywords: | dbr added |
---|
comment:6 Changed 10 years ago by
Summary: | Drag gets messed up when document flow changes → Draggable: Dragged element mouse offset is incorrect when document flow changes |
---|
Thanks for contributing, although you didn't need to be so rude about it, DUH! This is confirmed on latest: http://jsfiddle.net/6cfVD/