Hey Deco,

Deco Rior a écrit :
> I need the 'focusout' event. But Event.observe does not seem to  
> recognize this?

Well, first, the event name is 'DOMFocusOut' [1].  Second, it is not,
AFAIK, recognized yet by several browsers, most prominently IE.  Third,
it is semantically identical to 'blur'.  So I fail to see how this helps
you out.

I believe you'll have to hack around this, like:

- Use a boolean stating whether suggestions are displayed, using the
onShow/onHide callback functions.
- Still use, as I described earlier, a boolean stating whether a value
was selected (defaults to false, set to true through your
afterUpdateElement callback).
- Observe onblur, and validate only when your first boolean states no
suggestions are displayed.

Kinda tricky, but should do it.

[1]
http://www.w3.org/TR/DOM-Level-2-Events/events.html#Events-eventgroupings-uievents

-- 
Christophe Porteneuve a.k.a. TDD
"[They] did not know it was impossible, so they did it." --Mark Twain
Email: [EMAIL PROTECTED]

--~--~---------~--~----~------------~-------~--~----~
 You received this message because you are subscribed to the Google Groups 
"Ruby on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to