Modal dialogs + Close socket and worker on exit