persist the window visibility between connects