prepare code for new onclose event, but comment out