added listener to titleLayout in order to close the dialog