

function FindPosition(image_name){
    if(!document.images[image_name]){
        return null;
    }
    this.image_name = image_name;
    this.xPos = 500;
    this.yPos = 500;
    this.ref_image = document.images[image_name];
    this.getRealLeft = getRealLeft;
    this.getRealTop = getRealTop;
    this.getRealLeft();
    this.getRealTop();
}

function getRealLeft(move) {
   if(!move){
        move = 0;
    }
   if(document.layers){
     this.xPos = this.ref_image.x + move;    
     return this.xPos;
   }
	this.xPos = this.ref_image.offsetLeft;
	tempEl = this.ref_image.offsetParent;
  	while (tempEl != null) {
  		this.xPos += tempEl.offsetLeft;
  		tempEl = tempEl.offsetParent;
  	}
    this.xPos = this.xPos + move;
	return this.xPos;
}

function getRealTop(move) {
    if(!move){
        move = 0;
    }
    if(document.layers){
     this.yPos = this.ref_image.y + move; 
     return this.yPos
   }
	this.yPos = this.ref_image.offsetTop;
	tempEl = this.ref_image.offsetParent;
	while (tempEl != null) {
  		this.yPos += tempEl.offsetTop;
  		tempEl = tempEl.offsetParent;
  	}
    this.yPos = this.yPos + move;
	return this.yPos;
}



function showMenu(menu){
	switch(menu){
		case "menu1":
		oM.m["menu1"].b.moveIt(dropmenu1.xPos,dropmenu1.yPos+26);
		break;
		case "menu2":
		oM.m["menu2"].b.moveIt(dropmenu2.xPos,dropmenu2.yPos+26);
		break;
		case "menu3":
		oM.m["menu3"].b.moveIt(dropmenu3.xPos,dropmenu3.yPos+20);
		break;

	}
	oM.showsub(menu);
	
}


var dropmenu1 = new  FindPosition("personal");
var dropmenu2 = new  FindPosition("business");



oM=new makeCM("oM"); 
oM.resizeCheck=0; 
oM.rows=1;  
oM.onlineRoot=""
oM.offlineRoot=""
oM.pxBetween=0; 
oM.fillImg=imgdir+"clearpix.gif"; 
oM.fromTop=0; 
oM.fromLeft=0; 
oM.wait=300; 
oM.zIndex=400;
oM.useBar=0; 
oM.barWidth="0"; 
oM.barHeight="menu"; 
oM.barX=0;
oM.barY="menu"; 
oM.barClass="clB";
oM.barBorderX=0; 
oM.barBorderY=0;
db='<span class="bullet">&#149; </span>';

//oM.level[0]=new cm_makeLevel(width,height,regClass,overClass,borderX,borderY,borderClass,rows,align,offsetX,offsetY,arrow,arrowWidth,arrowHeight)
oM.level[0]=new cm_makeLevel(0,0,"bordercolor","bordercolor",0,0,"clB",0,"bottom",0,0,0,0,0);
/* oM.level[0].filter="progid:DXImageTransform.Microsoft.Alpha(opacity=100, finishopacity=100, style=3)"; */
oM.level[0].filter="PROGID:DXImageTransform.Microsoft.Alpha(opacity=97, finishopacity=87, style=1)"; 

oM.level[1]=new cm_makeLevel(109,25,"item_off","item_on",1,1,"clB",0,"right",0,0,imgdir+"tri.gif",5,10);
oM.level[1].roundBorder=1;

oM.level[2]=new cm_makeLevel(220,25,"item_off","item_on",1,1,"clB",0,"right",0,0,imgdir+"tri.gif",5,10);
oM.level[2].roundBorder=1;

//var dropmenu3 = new  FindPosition("ibmoreinfo");

/******************************************
Menu item creation:
myCoolMenu.makeMenu(name, parent_name, text, link, target, width, height, regImage, overImage, regClass, overClass , align, rows, nolink, onclick, onmouseover, onmouseout) 
*************************************/
oM.makeMenu('menu1');
	oM.makeMenu('menu1_1','menu1','Deposit Services',sitedir+'personal_deposit.html');
		oM.makeMenu('menu1_1_1','menu1_1','Checking Accounts',sitedir+'personal_checking.html');
			oM.makeMenu('menu1_1_1_1','menu1_1_1','Founder\'s Checking Account',sitedir+'personal_checking.html#founder');
			oM.makeMenu('menu1_1_1_2','menu1_1_1','Founder\'s Checking Account <br>+ Interest',sitedir+'personal_checking.html#founder_interest', '', '', '40','','','','','','2');
			/*oM.makeMenu('menu1_1_1_3','menu1_1_1','Regular Checking',sitedir+'personal_checking.html#regular');
			oM.makeMenu('menu1_1_1_4','menu1_1_1','Regular Checking Account + Interest',sitedir+'personal_checking.html#regular_interest');
			oM.makeMenu('menu1_1_1_5','menu1_1_1','Value Checking Account',sitedir+'personal_checking.html#value');*/
			oM.makeMenu('menu1_1_1_3','menu1_1_1','FREEdom Checking',sitedir+'personal_checking.html#freedom');
			oM.makeMenu('menu1_1_1_4','menu1_1_1','FREEdom Heritage Checking',sitedir+'personal_checking.html#freedom_htg');
			oM.makeMenu('menu1_1_1_5','menu1_1_1','Economy Checking Account',sitedir+'personal_checking.html#free');
			oM.makeMenu('menu1_1_1_6','menu1_1_1','Money Market Accounts',sitedir+'personal_checking.html#money');
		oM.makeMenu('menu1_1_2','menu1_1','Savings Accounts, CD\'s, and IRA\'s',sitedir+'personal_savings.html');
			oM.makeMenu('menu1_1_2_1','menu1_1_2','Personal Savings',sitedir+'personal_savings.html#personal');
			oM.makeMenu('menu1_1_2_2','menu1_1_2','Youth Savings',sitedir+'personal_savings.html#youth');
			oM.makeMenu('menu1_1_2_3','menu1_1_2','Certificates of Deposit',sitedir+'personal_savings.html#cd');
			oM.makeMenu('menu1_1_2_4','menu1_1_2','Individual Retirement Account',sitedir+'personal_savings.html#ira');
		oM.makeMenu('menu1_1_3','menu1_1','Rates',sitedir+'rates.html');
	oM.makeMenu('menu1_2','menu1','Loan Services',sitedir+'personal_loan.html');
	oM.makeMenu('menu1_3','menu1','Other Services',sitedir+'personal_other.html');
		

			
oM.makeMenu('menu2');
	oM.makeMenu('menu2_1','menu2','Deposit Services',sitedir+'business_deposit.html');
		oM.makeMenu('menu2_1_1','menu2_1','Online Cash Management',sitedir+'business_other.html#cm');
		oM.makeMenu('menu2_1_2','menu2_1','Interbank Funds Transfers',sitedir+'business_other.html#fund');
		oM.makeMenu('menu2_1_3','menu2_1','Remote Capture',sitedir+'business_other.html#capture');
		oM.makeMenu('menu2_1_4','menu2_1','Checking Accounts',sitedir+'business_checking.html');
			oM.makeMenu('menu2_1_4_1','menu2_1_4','Business Analysis Checking',sitedir+'business_checking.html#analysis');
			oM.makeMenu('menu2_1_4_2','menu2_1_4','Business Checking',sitedir+'business_checking.html#checking');
			oM.makeMenu('menu2_1_4_3','menu2_1_4','Business Value Checking',sitedir+'business_checking.html#value');
			oM.makeMenu('menu2_1_4_4','menu2_1_4','Business Value Checking for Non-Profit Organizations',sitedir+'business_checking.html#nonprofit', '', '', '40');
			oM.makeMenu('menu2_1_4_5','menu2_1_4','Money Market Accounts',sitedir+'business_checking.html#money');
		oM.makeMenu('menu2_1_5','menu2_1','Certificates of Deposit',sitedir+'business_cd.html');
		oM.makeMenu('menu2_1_6','menu2_1','Rates',sitedir+'rates.html');
	oM.makeMenu('menu2_2','menu2','Loan Services',sitedir+'business_loan.html');
	oM.makeMenu('menu2_3','menu2','Cutoff Times',sitedir+'business_other.html#cutoff');
	oM.makeMenu('menu2_4','menu2','Other Services',sitedir+'business_other.html#other');
		
	
oM.makeMenu('menu3');
	oM.makeMenu('menu3_1','menu3','Apply','javascript:testForDemo(\'https://www.tcbtexasonline.com/onlineserv/HB/STDReg.cgi\');','',120);
	oM.makeMenu('menu3_2','menu3','Demo', homedir + 'home.html?demo','',120);
	oM.makeMenu('menu3_3','menu3','Forgot Password','javascript:testForDemo(\'https://www.tcbtexasonline.com/onlineserv/HB/ForgottenPW.html\');','',120);
	oM.makeMenu('menu3_4','menu3','Change Password','javascript:testForDemo(\'https://www.tcbtexasonline.com/onlineserv/HB/dimlDisplayer.cgi?DIML_FILE=passwordReset.diml\');','',120);
	oM.makeMenu('menu3_5','menu3','FAQs', sitedir + 'faq-internetbanking.html','',120);
	oM.makeMenu('menu3_6','menu3','Info for AOL Users','https://www.tcbtexasonline.com/onlineserv/HB/aol.html','_blank',120);
	oM.makeMenu('menu3_7','menu3','Login Help', 'https://www.tcbtexasonline.com/onlineserv/HB/login_help.html','_blank',120);
	oM.makeMenu('menu3_8','menu3','Disclosure','https://www.tcbtexasonline.com/onlineserv/HB/disclose.html','_blank',120);
	
oM.menuPlacement=new Array(0);
oM.construct();

//end of file
