Fixed bug: AbstractDialog.onClose() does not work