(function(g){var f={},i="doTimeout",h=Array.prototype.slice;g[i]=function(){return e.apply(window,[0].concat(h.call(arguments)))};g.fn[i]=function(){var a=h.call(arguments),b=e.apply(this,[i+a[0]].concat(a));return typeof a[0]==="number"||typeof a[1]==="number"?this:b};function e(q){var d=this,u,r={},v=q?g.fn:g,c=arguments,t=4,w=c[1],s=c[2],a=c[3];if(typeof w!=="string"){t--;w=q=0;s=c[1];a=c[2]}if(q){u=d.eq(0);u.data(q,r=u.data(q)||{})}else{if(w){r=f[w]||(f[w]={})}}r.id&&clearTimeout(r.id);delete r.id;function x(){if(q){u.removeData(q)}else{if(w){delete f[w]}}}function b(){r.id=setTimeout(function(){r.fn()},s)}if(a){r.fn=function(j){if(typeof a==="string"){a=v[a]}a.apply(d,h.call(c,t))===true&&!j?b():x()};b()}else{if(r.fn){s===undefined?x():r.fn(s===false);return true}else{x()}}}})(jQuery);(function(a){a.fn.hoverIntent=function(k,j){var l={sensitivity:7,interval:100,timeout:0};l=a.extend(l,j?{over:k,out:j}:k);var n,m,h,d;var e=function(f){n=f.pageX;m=f.pageY};var c=function(g,f){f.hoverIntent_t=clearTimeout(f.hoverIntent_t);if((Math.abs(h-n)+Math.abs(d-m))<l.sensitivity){a(f).unbind("mousemove",e);f.hoverIntent_s=1;return l.over.apply(f,[g])}else{h=n;d=m;f.hoverIntent_t=setTimeout(function(){c(g,f)},l.interval)}};var i=function(g,f){f.hoverIntent_t=clearTimeout(f.hoverIntent_t);f.hoverIntent_s=0;return l.out.apply(f,[g])};var b=function(q){var o=(q.type=="mouseover"?q.fromElement:q.toElement)||q.relatedTarget;while(o&&o!=this){try{o=o.parentNode}catch(q){o=this}}if(o==this){return false}var g=jQuery.extend({},q);var f=this;if(f.hoverIntent_t){f.hoverIntent_t=clearTimeout(f.hoverIntent_t)}if(q.type=="mouseover"){h=g.pageX;d=g.pageY;a(f).bind("mousemove",e);if(f.hoverIntent_s!=1){f.hoverIntent_t=setTimeout(function(){c(g,f)},l.interval)}}else{a(f).unbind("mousemove",e);if(f.hoverIntent_s==1){f.hoverIntent_t=setTimeout(function(){i(g,f)},l.timeout)}}};return this.mouseover(b).mouseout(b)}})(jQuery);
