save window states of open dialogs