<!--
/* ***************************************************
Contains User Interface behavior methods.  

NOTE: Reuse without permission is prohibited.
Copyright enLogica, Inc. 2005
neal.cabage@enlogica.com

01. popUp(sLocArg,iHeight,iWidth, bScroll)
02. rollOver(imgName,trueFalse)
03. visibleLayer(layerName,TrueOrFalse)
04. go(sLocArg)
05. toggle(bVar)
06. status(msg)
07. clearfield(field)
08. setParentLoc(url)
**************************************************** */

//var actionWindow;

/* Open a child window.*/	
function popUp(sLocArg,iHeight,iWidth,bScrolling,bMenubar,windowName) {

    if (iHeight==null) {iHeight=550}
    if (iWidth==null) {iWidth=550}	
    if (bScrolling=='true' || bScrolling==true) {sScroll="yes"}	
	else{sScroll="no"}
	if (bMenubar=='true' || bMenubar==true) {sMenu="yes"}	
    else{sMenu="no"}
	if (windowName==null){windowName='action'}
    sProps = "height="+iHeight+",width="+iWidth+",scrollbars="+sScroll+",menubar="+sMenu;
	
	window.open(sLocArg,windowName,sProps);
}


/* Rollover buttons. Pass name of image and a boolean indicating
   if the rollOver state of the button should be shown or not. */
function rollOver(imgName,trueFalse) {
	if (document.images && trueFalse==true) {
    	document[imgName].src = eval(imgName + "_on.src");
    }else if (document.images && trueFalse==false) {
    	document[imgName].src = eval(imgName + "_off.src");
	}
}


/* Adjust layer visibility, provided layer name and boolean state. */
function visibleLayer(layerName,TrueOrFalse) {

	//Which state to show.		
	if (TrueOrFalse) {sVis = "visible"}
	else{sVis = "hidden"}
	
	document.getElementById(layerName).style.visibility=sVis;	
}

function displayLayer(layerName,TrueOrFalse) {

	//Which state to show.		
	if (TrueOrFalse) {sVis = "inline"}
	else{sVis = "none"}
	
	document.getElementById(layerName).style.display=sVis;	
}

/* Redirects to a different location */	
function go(sLocArg){
	if (sLocArg!=""){
    	location.href=sLocArg;	
	}
}	


/* Toggle a boolean value */
function toggle(bVar) {
	bFlag = true;
	if (bVar) bFlag=false;
	return bFlag;			
}


/* Place message into status bar. */
function status(myMsg) {
    window.status = myMsg;
    return(true);
}


/* clear specified field */
function clearfield(field) {
	field.value="";
}

function setParentLoc(uri){
	window.opener.location=uri;
}

//-->		
