fix bugs with modal, change modal buttons text, reset modal at terminate.
RT