javascript - jQuery mobile misses css effects on vclick/fastclick -


as has used jqm on android/ios device knows, 300ms delay can cause headaches. thankfully there variety of solutions -- use fastclick.js, "vlick" method, , other options.

however, when apply solutions, css effects don't follow through. here's demo: http://nischenspringer.de/jquery/fastclick/demo.html (from https://github.com/plaputta/jquery.event.special.fastclick)

if click around demo on computer, see hover , click css effects. however, if click ios device, see effects when hold on button 300ms (i assume). if click quickly, application respond , action, not see css changes!

any ideas on how fix this??

working example: jsfiddle

all have set jquery mobile config variable: buttonmarkup.hoverdelay

$(document).bind("mobileinit", function(){     $.mobile.buttonmarkup.hoverdelay = 0; }); 

but careful, mobileinit must initialized before jquery mobile, this:

<script src="jquery.js"></script> <script>     $(document).bind("mobileinit", function(){         $.mobile.buttonmarkup.hoverdelay = 0;     }); </script> <script src="jquery-mobile.js"></script> 

Comments

Popular posts from this blog

python - How to create a legend for 3D bar in matplotlib? -

java - Multi-Label Document Classification -

php - Dynamic url re-writing using htaccess -