Brian, from looking at your demo, i think this is great! What i find nice is that it seems to make the animation smoother. Apparently, it gives the browser a few moments to think before acting, which my FF2 appreciates (and my IE7 too). Now, to put it under stress, i would like to see if it can solve the bad animation in such applications as this one: HYPERLINK "http://www.eogallery.com/"http://www.eogallery.com/ i know what you wanted is to reduce accidental event triggering, but since there is a nice side effect, why not exploit it?
_____ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brian Cherne Sent: mardi 13 mars 2007 9:53 To: jQuery Discussion. Subject: [jQuery] hoverIntent = my first plug-in WHAT? hoverIntent is a function that attempts to determine the user's intent... like a crystal ball, only with mouse movement! It works like (and was derived from) jQuery's built-in hover. However, instead of immediately calling the onMouseOver function, it waits until the user's mouse slows down enough before calling the function. WHERE? My sorely out-dated web site. <HYPERLINK "http://cherne.net/brian/resources/jquery.hoverIntent.html" \nhttp://cherne.net/brian/resources/jquery.hoverIntent.html > WHY? To delay or prevent the accidental firing of animations or ajax calls. Simple timers work for small areas, but if your target area is large it may execute regardless of intent. Also, because jQuery animations cannot be stopped once they've started it's best not to start them prematurely. ... and I wanted something that was easy to swap in/out with hover (so hoverIntent returns the same "this" and event objects as hover). WHAT'S NEXT? Your feedback! Tear it shreds! Tell me what you think. I would like to keep the script as small as possible, but if I could make this more useful (and more likely to be used) I'm happy to make some enhancements... like... - more compelling/verbose demo/documentation - ability to override default settings (sensitivity, polling interval, etc) - option of a simple onMouseOut timer - make it more jQuery $-friendly (first few attempts have failed) - suggestions for code style/commenting/optimization Thanks in advance, Brian. -- Ce message Envoi est certifié sans virus connu. Analyse effectuée par AVG. Version: 7.5.447 / Base de données virus: 268.18.10/720 - Date: 12/03/2007 19:19
_______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/