Column render, listen to click event of a <i> tag?
I have a render function on a grid column that basically returns some html, the html consists of a tag to display an icon and then some text. Sort of like this
<i class="some class"> </i> some text
I only want to attach a click event to the i tag, not the text, so itemClick wouldn't work. How do I attach ane element listener just to the i tag that is returned from my render function ?
A little lost ? Any ideas?
I did look at use a columnaction but i can only use an img, and no text can be set after the image.
Any ideas ?
Thanks
听取cellclick事件,然后检查事件目标:
listeners: {
cellclick: function(grid, td, cellIndex, record, tr, rowIndex, e) {
if (cellIndex === whatever && Ext.fly(e.target).hasCls('foo')) {
// Go
}
}
}
链接地址: http://www.djcxy.com/p/67648.html
上一篇: 为什么我不能在C ++ 11中创建一个lambda表达式(相同类型的)?
下一篇: 列渲染,听取<i>标签的点击事件?