// Browser portable event handler
function myEventHandler(anEvent)
{
if(navigator.appName.indexOf("Microsoft") != -1)
{
anEvent = window.event;
anEvent.srcElement = target;
anEvent.button = which;
anEvent.keyCode = which;
anEvent.altKey = anEvent.modifiers & Event.ALT_MASK;
anEvent.ctrlKey = anEvent.modifiers & Event.CONTROL_MASK;
anEvent.shiftKey = anEvent.modifiers & Event.SHIFT_MASK;
anEvent.clientX = pageX;
anEvent.clientY = pageY;
}
// Portable event code goes here.
}| See also: | Element.onevent |
| Prev | Home | Next |
| Event | Up | Event bubbling |
JavaScript Programmer's Reference, Cliff Wootton Wrox Press (www.wrox.com) Join the Wrox JavaScript forum at p2p.wrox.com Please report problems to support@wrox.com © 2001 Wrox Press. All Rights Reserved. Terms and conditions. | ||