如何关闭jqGrid的列突出显示(悬停时)? [英] How to turn off column highlighting (on hover) for a jqGrid?

查看:633
本文介绍了如何关闭jqGrid的列突出显示(悬停时)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题的标题很好地总结了(某种).如果启用了jQuery主题,如何删除jqGrid中列的悬停效果以及鼠标悬停的作用?

Title of the questions sums it up quite nicely (kind of). How do I remove the hover effect of a column in jqGrid, plus the mouse-over hand, if I have jQuery themes enabled?

通过编辑与jqGrid关联的css,此更改一定不会影响同一页面上或系统范围内的其他网格.

This change must not affect and other grids that may be on the same page, or system wide by editing the css associated with jqGrid.

推荐答案

我在此处回答了相同的问题,但是因为该问题是累积性"问题,其中包含多个问题,可能很难在stackoverflow上找到.

I answered the same question here, but because the question was "cumulative" question with multiple questions it can be difficult be found on the stackoverflow.

jqGrid使用 jQuery.hover mouseentermouseleave绑定到作为列标题的元素(请参见该行代码).因此,只需在创建网格后解除绑定事件即可.为此,可以使用类似

jqGrid use jQuery.hover to bind mouseenter and mouseleave to the <th> elements which are column headers (see the line of code). So one need just unbind the events after the grid is created. To do this one can use the code like

$($("#gridId")[0].grid.hDiv).find(".ui-jqgrid-labels th.ui-th-column")
    .unbind("mouseenter")
    .unbind("mouseleave");

这篇关于如何关闭jqGrid的列突出显示(悬停时)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆