SlickGrid 中的单元格工具提示 [英] Cell tooltip in SlickGrid
本文介绍了SlickGrid 中的单元格工具提示的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的 SlickGrid 表格中的某些单元格具有 myClass
类.
Some cells in my SlickGrid table have myClass
class.
我为他们添加了这样的工具提示:
I added a tooltip for them like this:
$(".myClass").hover(// Mouse enters
function(e) {...},
// Mouse leaves
function() {...});
它工作正常,但如果我将表格滚动到底部,然后将其滚动回顶部,工具提示将不再出现.
It works fine, but if I scroll the table to the bottom, and then scroll it back to the top, the tooltip does not appear anymore.
有人可以建议任何解决方法吗?
Can someone suggest any workaround ?
谢谢!
推荐答案
尝试:
$('.myClass').live('mouseover mouseout', function(event) {
// works only on jQuery 1.4.1 and up
if (event.type == 'mouseover') {
// Mouse enters
} else {
// Mouse leaves
}
});
如果这不起作用,我猜 .myClass
已被删除,因此请尝试在每个卷轴中再次添加它...
if that doesn't work, I'm guessing .myClass
has been remove so try adding it again in every scrolls...
无论哪种方式,使用 live()
这篇关于SlickGrid 中的单元格工具提示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文