
// File = Includes/Js/Dialogs/Dialogs.js

function ShowDialog(dlgPath, dlgName, dlgArgs){
	
	var dlgFullPath = dlgPath + dlgName + ".htm";
	
	// set dialog height & width
	sDlgType = dlgArgs.DlgType;
	switch(dlgName){
		case "DlgOK":
			dlgHeight = 200;
			dlgWidth = 450;
			break;								
		case "DlgYesNo":
			switch(sDlgType){
				case "DelMember":
					dlgHeight = 180;
					dlgWidth = 400;
					break;
				default:
					dlgHeight = 230;
					dlgWidth = 460;
					break;	
			}
			break;
		default:
			break;		
	}
	
	var dlgFeatures = GetDlgFeatures(dlgHeight, dlgWidth); 
	return window.showModalDialog(dlgFullPath,dlgArgs,dlgFeatures);
}

function GetDlgFeatures(dlgHeight, dlgWidth){

	var sFeatures = "dialogHeight: " + dlgHeight + "px;"
	sFeatures += "dialogWidth: " + dlgWidth + "px;"
	sFeatures += "help:No;scroll:No;"
	
	return sFeatures;
}

