Here's a patch which adds timed menu hiding when mousing outside of a menu. This keeps menus from "popping" away when you sloppily mouse past the edge.

This is very lightweight, less flexible script than Superfish. And like Sucker/Superfish, it should degrade gracefully in non-IE browsers without JS support.

A very cool side effect of this script is that it negates the need for the IE-only javascript. The admin_menu.js file runs for all browsers now and the IE-stuff happens conditionally within it. No need for <!-- if lt IE 7 --> in the document head anymore.

Tested on Firefox, Safari, and IE 6 and it's working great in all of 'em.

Enjoy!

Comments

sun’s picture

Title: Patch to add superfish-style delayed menu hiding » Usability: add mouseout delay for hovered menus
Version: 5.x-2.1 » 5.x-2.x-dev
Category: feature » task
Status: Active » Needs review
StatusFileSize
new3.67 KB

Thanks, this looks very promising!

Re-rolled patch against current 5.x-2.x, not yet tested.

However, the .sfhover/.iehover classes were only needed for IE 6 previously. IE 7 seems to support the universal :hover style finally.

sun’s picture

StatusFileSize
new3.71 KB

Based on the jQuery docs, we should be able to use parseInt($.browser.version) to specifically detect IE 6.

Added in attached patch.

sun’s picture

Status: Needs review » Fixed

Holy shit! Jeff, you rock!

Tested in Firefox 2, IE 6, Opera 9 and Safari 3 and committed!

Thank you!

smk-ka’s picture

Title: Usability: add mouseout delay for hovered menus » Usability: reduce mouseout delay for hovered menus
Version: 5.x-2.x-dev » 5.x-2.2
Status: Fixed » Active

Mouseout delay rocks! However, am I the only one who finds it too slow? I'd prefer having around 400 msec delay, just enough time to move the mouse pointer back on the menu and not having the menu in my way when I want it to disappear.

yched’s picture

agreed :-) current value is a bit slow IMO

sun’s picture

Status: Active » Needs review
StatusFileSize
new528 bytes

Please test attached patch.

yched’s picture

Status: Needs review » Reviewed & tested by the community

soo much better !

sun’s picture

Status: Reviewed & tested by the community » Fixed

Thanks, committed!

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.