change dialog titles according to state of dialog