locking in jquery 1.8