Sunday, May 19, 2024
 Popular · Latest · Hot · Upcoming
83
rated 0 times [  84] [ 1]  / answers: 1 / hits: 43990  / 16 Years ago, wed, march 4, 2009, 12:00:00

I am able to find the cursor position. But I need to find out if the mouse is stable. If the mouse wasn't moved for more than 1 minute, then we have to alert the user.



How its possible, are there any special events for this? (Only for IE in javascript)


More From » events

 Answers
7

Set a timeout when the mouse is moved one minute into the future, and if the mouse is moved, clear the timeout:



var timeout;
document.onmousemove = function(){
clearTimeout(timeout);
timeout = setTimeout(function(){alert(move your mouse);}, 60000);
}

[#99892] Thursday, February 26, 2009, 16 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
wyattkennyc

Total Points: 650
Total Questions: 102
Total Answers: 90

Location: Monaco
Member since Mon, May 23, 2022
2 Years ago
;