On 4/18/07, Morten Barklund <[EMAIL PROTECTED]> wrote:
> visual effects? Effects that could easily be achieved with some
> onmouseover-, onmouseout-callbacks? And then you want to fix your easy
> workaround with strange javascript? I would fix the cause, not the
> sideeffect :)
This worked out really well, and simplified the handlers. Thanks!
I now have these handlers:
function mouseover(evt) {
addElementClass(evt.src(), "hovering");
}
function mouseout(evt) {
removeElementClass(evt.src(), "hovering");
}
and this for registrations:
connect(anchor, "onmouseover", mouseover);
connect(anchor, "onmouseout", mouseout);
I find this all surprisingly readable -- JavaScript and I usually
aren't on speaking terms.
-Fred
--
Fred L. Drake, Jr. <fdrake at gmail.com>
"Chaos is the score upon which reality is written." --Henry Miller
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"MochiKit" 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/mochikit?hl=en
-~----------~----~----~----~------~----~------~--~---