I try to build a really simple screensaver, but it is not as easy as I thought.
My solution did not really work and it is IMHO really dirty.
Did anyone have a good clean idea? Maybe without a timeout?
HTML
<div id="screensaver" style="width:100%; height:100%; background-color:#000000; display:none;" > </div>
JS
$('body').live('mousemove', function (e)
{
if (e.type == 'mousemove')
{
clearTimeout(s_saver);
s_saver = setTimeout('$(\'#screensaver\').fadeIn();', 4000);
$('#screensaver').hide();
}
});
Thanks in advance!
Peter