jQuery value change event delay
<p>I want to execute a function like 2 seconds after a user has finished typing in the textbox. If they continue to type after 1 second, the delay time is reset back to 2.</p>

<p>It should function something similar to an autocomplete box.</p>

<p>I know of 2 events: <code>change</code> and <code>keyup</code>. The problem I have with <code>change</code> is that the textbox has to loose focus for it to be triggered. for <code>keyup</code>, what if they use the mouse to paste a text?</p>

<p>Could I be helped here?</p>
