I just recently got an android phone and found that the drag and drop on my site doesn't work! I understand why it wouldn't, but has anyone found a solution to this? I'm using JQuery to implement the D & D...
To drag. Put a finger on the desired point on the touch screen and slide the finger.
The Android drag and drop framework enables you to add interactive drag and drop capabilities to your app. With drag and drop, users can copy or move text, images, objects—any content that can be represented by a URI—from one View to another within an app or, in multi-window mode, between apps.
I used jQuery UI touch punch - it works by hacking the mousedown, mouseup features and replaces them with touchstart, touchend etc.
ABOUT: http://touchpunch.furf.com/
SCRIPT: https://raw.github.com/furf/jquery-ui-touch-punch/master/jquery.ui.touch-punch.min.js
CODE:
include:
<script src="jquery.ui.touch-punch.min.js"></script>
after your jquery UI script file in your header.
I used the touchpunch answer above and it worked great. One note on it, though. I found that using the github link on the site (and above):
SCRIPT: https://raw.github.com/furf/jquery-ui-touch-punch/master/jquery.ui.touch-punch.min.js
did not work for Android devices running mobile Chrome, but the raw, human readable source from the site did work. This is as of the date of this posting, it may get fixed of course, but in the mean time maybe it will save you a few cycles of debugging.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With