Bug Description:
The Click event cannot be triggered under iOS, android4.4+.
Bug fixes:
Call the Iscroll plugin to add configuration parameters: Click:true/false
Click the value is to judge according to mobile terminal equipment, if it is simply to determine the type of terminal, android4.4+ still can not click, this is an android pit, after all, there is no unified iOS system.
So add a function to judge:
######## #function Iscrollclick () {if (/iphone|ipad|ipod| Macintosh/i.test (navigator.useragent)) return false;if (/chrome/i.test (navigator.useragent)) return (/Android/ I.test (navigator.useragent)); if (/silk/i.test (navigator.useragent)) return False;if (/android/i.test ( navigator.useragent)) { var s=navigator.useragent.substr (navigator.userAgent.indexOf (' Android ') +8,3); Return parsefloat (S[0]+s[3]) < 44? False:true }}
Configuration instance:
Myscroll = new Iscroll ("#ID", {Click:iscrollclick (),//Call judgment function scrollbars:true,//have scroll bar mousewheel:true,// Allow pulley scrolling fadescrollbars:true//scroll bar, default shadow, and fade-in effect });
iscroll5+ on iOS, Android Click events not compatible workaround