android - jQuery 移动按钮按下事件处理缓慢

标签 android ios cordova jquery-mobile

似乎每当我在移动设备上按下输入按钮或 anchor 按钮时,都需要一两秒钟来处理 onclick 或 press 事件。有什么办法可以加快速度吗?

我在 Android 设备上使用 Phonegap + jQuery Mobile,在 iOS 上似乎快一点

最佳答案

来自 http://jquerymobile.com/demos/1.2.0/docs/pages/phonegap.html

$.mobile.buttonMarkup.hoverDelay

If you find that the button down/hover state (lists, buttons, links etc) feels sluggish the $.mobile.buttonMarkup.hoverDelay setting might be of use. It will decrease the time between the touch event and the application of the relevant class but will also result in a higher chance that the same class will be applied even when the user is scrolling (eg, over a long list of links).

例如:

$( document ).bind( "mobileinit", function() {
    $.mobile.buttonMarkup.hoverDelay = 500
});

关于android - jQuery 移动按钮按下事件处理缓慢,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16630129/

相关文章:

javascript - 在温泉菜单上传递参数

java - 复选框右对齐

android - 您将如何在 Android 中创建弹出 View ,例如 Facebook 评论?

android - 通过 DialogFragment android 将 TimePickerDialog 的结果设置为按钮

ios - 继承 UIButton 外观的 UITableViewCell 披露指示器

ios - 在 iOS 中以编程方式连接蓝牙耳机?

android - Retrofit2 - 缺少@GET URL 或@Url 参数 - Proguard

ios - 使用 dequeueReusableCellWithReuseIdentifer 时出错

javascript - Phonegap & Javascript -- Div 的动态调整大小

android - HTML5 Android Phonegap Web 应用程序无法使用缓存 list 离线工作