popup dialogs bug fixes