Change the name of the dialog panel to distinguish when the dialog panel events are executed which of them fired the event.

ts_dialog( int iDialogDescr, string snew_sDescr);


Here:

iDialogDescr - descriptor of the dialog to change;

snew_sDescr is a new name for recognizing a dialog (or dialog state) in a program.