【发布时间】:2012-03-11 14:52:51
【问题描述】:
我正在使用这段很棒的代码来模拟 Android http://pervasivecode.blogspot.co.nz/2011/11/android-phonegap-active-css-pseudo.html 上的触摸事件。效果很好,但太敏感了。例如,如果您有一个列表,并且想要在您触摸列表上任何它突出显示的链接时向下滚动。
$(document).ready(function(){
if (navigator.userAgent.toLowerCase().indexOf("android") > -1) {
$('a')
.bind("touchstart", function () {
$(this).addClass("fake-active");
})
.bind("touchend", function() {
$(this).removeClass("fake-active");
});
}
});
是否可以延迟课程更改或者我可以使用其他触发器?
【问题讨论】:
标签: jquery android web-applications jqtouch