set up even handlers while(1) { e = EventQueue.dequeue(); DispatchEvent(e); }
function OnClick(e) { e.stopPropagation(); ... };
Messages from the canvas will show up here:
Canvas Message Area
Messages from the wrapper will show up here:
Wrapper Message Area
canvas = document.getElementById("eventCanvas"); canvas.tabIndex = 0;
canvas.addEventListener("click", MyHandler); canvas.addEventListener("keydown", MyHandler); canvas.addEventListener("focus", MyHandler); canvas.addEventListener("wheel", MyHandler);