adding resize event