Skip to content

Conversation

@bbreukelen
Copy link

  1. Resolved and issue where a drag event would result in a click event after dropping.
    Decision based on the the length of the tap/drag event and the distance moved.
  2. Dragging while zoomed in caused issues where the draggable showed at an incorrect position on the screen making it unusable.
    I applied the fix from Kocik's fork. Note that this only works if the container in which the draggable resides has a position: relative. Here is the fork: https://github.com/Kocik/jquery-ui-touch-punch-zoom-fork, thanks Kocik!

1. Resolved and issue where a drag event would result in a click event after dropping.
    Decision based on the the length of the tap/drag event and the distance moved.
2. Dragging while zoomed in caused issues where the draggable showed at an incorrect position on the screen making it unusable.
   I applied the fix from Kocik's fork. Note that this only works if the container in which the draggable resides has a position: relative.   Here is the fork: https://github.com/Kocik/jquery-ui-touch-punch-zoom-fork, thanks Kocik!
@tinnielam
Copy link

Recently I had a problem when I tried to click in a draggable.

Your fix actually worked, now I am able to click a button or someelement in a draggable div.

@RWAP
Copy link

RWAP commented Jan 29, 2019

The lines:

touch.clientX + $(window).scrollLeft(), // clientX + scrollLeft - fix for zoomed devices while dragging touch.clientY + $(window).scrollTop(), // clientY + scrollTop - fix for zoomed devices while dragging

Seem to prevent jQuery.ui sortable from allowing you to drop the item you move on Android and iphone machines...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants