add beforeClose method, remove close events