reset instance state then dialog is closed