added changes to ckick event