<script src="http://code.jquery.com/jquery-latest.js"></script>
<input id=btn type="button" />
<script>
$('#btn').click(function () {
test($(this));
});
var Id0Timeout;
function test(a) {
clearTimeout(Id0Timeout);
Id0Timeout= setTimeout(function () {
alert('a1');
}, 3000);
}
</script>
script