0
我一直在围绕模具用这一切的一天,并且不能看着办吧......jQuery的ButtonSet()悬停状态覆盖
我有()利用jQuery UI的buttonset(功能)按钮的列表和即使在我将鼠标悬停在某个按钮之后,我仍想保留ui-active
类,但由于某种原因,jQuery UI功能会一直移除该类并从按钮上清除高亮区(这很糟糕,因为用户不知道按钮是什么他们在)。
这是迄今为止代码:
function showSection(sectionIndex){
$('.listSection').hide();
$('#listSection' + sectionIndex).show();
$('.listSectionHeader.ui-state-active').each(function(){
$(this).removeClass('ui-state-active');
});
$('#listSectionHeader' + sectionIndex).addClass('ui-state-active');
}
var buttons = $("#listHeader a");
$.each(buttons, function(){
$(this).bind('mouseleave.button', function(){
if($(this).hasClass('ui-state-active'))
return;
});
});
你也可以发布你的html代码 – DG3 2012-02-29 21:53:22