I'm using Brian Cherne's hoverIntent.js
plugin for a project. It's a great plugin but it seems to be broken in jQuery 1.7.1.
I'm trying to debug it but I'm not the most ace javascripter out there. Can anyone tell me what I might need to look for in his code to fix the following error message:
Uncaught TypeError: Cannot call method 'apply' of undefined
That's what my Chrome console tells me. I'm just not sure what to change.
There is the following line of code in the plugin which contains apply
in the string
return cfg.over.apply(ob,[ev])}else{pX=cX;pY=cY;ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}};
EDIT
I should post the link to Brian's full commented code. It's here: http://cherne.net/brian/resources/jquery.hoverIntent.js
EDIT 2
My script is as follows
//#nav-main dropdown effects
$('#nav-main ul li').hoverIntent(function () {
$(this).find('.dropdown').stop(true,true).slideToggle('500');
});
hoverIntent
the dropdowns (since there are many of them) rapidly queue as you hover across. If there were ONE dropdown then your suggestion would be good, but with many,hoverIntent
is better.