【问题标题】:Click events in Sencha touchSencha touch 中的点击事件
【发布时间】:2014-07-29 09:33:40
【问题描述】:

我的列表项中有复选框,我想分别处理(复选框选中/取消选中和列表项单击)这些事件。我怎样才能做到这一点??我是sencha touch的新手,请帮助我。 现在我可以点击复选框,但 listItemTap 事件正在被调用。

【问题讨论】:

    标签: listview checkbox sencha-touch


    【解决方案1】:

    使用事件参数获取目标,像这样:-

    itemTapFn: function(list, index, target, record, e) {
    
        if (e.target.type === 'checkbox') {
            /* checkbox click functionality */
        } else {
            /* do itemtap functionality */
        }
    
    }
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-01-09
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多