removed exit on close, added hide on close