<html>
<head>
<title>Untitled Document</title>
</head>
<body onload="document.releaseCapture()">
<input onmouseover="alert('over');" onclick="alert('click')" type="text" value="aaaaaaaaaaaa"/>
<input onmouseover="alert('over');" onclick="alert('click')" type="text" value="bbbbbbbbbbbb"/>
</body>
</html>
I have a document which consumes lots of cpu and memory.
that's because I use javascript dom. I think.
when I move mouse just a bit, it demands cpu. so I want prevent it from capturing my mouse events other than the onclick event of the input boxes.
I mean I want the code above, just onclick event is supposed to work and on mouse event is not supposed to work.
what's wrong?
<head>
<title>Untitled Document</title>
</head>
<body onload="document.releaseCapture()">
<input onmouseover="alert('over');" onclick="alert('click')" type="text" value="aaaaaaaaaaaa"/>
<input onmouseover="alert('over');" onclick="alert('click')" type="text" value="bbbbbbbbbbbb"/>
</body>
</html>
I have a document which consumes lots of cpu and memory.
that's because I use javascript dom. I think.
when I move mouse just a bit, it demands cpu. so I want prevent it from capturing my mouse events other than the onclick event of the input boxes.
I mean I want the code above, just onclick event is supposed to work and on mouse event is not supposed to work.
what's wrong?