// rollover for all Forsyte Sections

var timeout_ForsyteId;
var timeout_ForsyteInternalId;

function preload_forsyteInternal() {
if(document.images) {
  var ImgArray = new Array();
  for (var i = 0; i < 8; i++) {
    ImgArray[i] = new Image();
  }    
	ImgArray[0].src = "images/forsyte_intrnl_essays.gif";
	ImgArray[1].src = "images/forsyte_intrnl_notes.gif";
	ImgArray[2].src = "images/forsyte_intrnl_credits.gif";
	ImgArray[3].src = "images/forsyte_intrnl_ntof.gif";
	ImgArray[4].src = "images/forsyte_intrnl_baker.gif";
	ImgArray[5].src = "images/forsyte_intrnl_episodes.gif";
	ImgArray[6].src = "images/forsyte_intrnl_links.gif";
	ImgArray[7].src = "images/forsyte_intrnl_forum.gif";
  }
}


function preload_forsyteEssay() {
if(document.images) {
  var ImgArray = new Array();
  for (var i = 0; i < 9; i++) {
    ImgArray[i] = new Image();
  }    
	ImgArray[0].src = "images/galsworthy_descrip.gif";
	ImgArray[1].src = "images/galsworthy_square.gif";
	ImgArray[2].src = "images/galsworthy_square_over.gif";
	ImgArray[3].src = "images/lewis_descrip.gif";
	ImgArray[4].src = "images/lewis_square.gif";
	ImgArray[5].src = "images/lewis_square_over.gif";
	ImgArray[6].src = "images/saga_descrip.gif";
	ImgArray[7].src = "images/saga_square.gif";
	ImgArray[8].src = "images/saga_square_over.gif";
  }
}

function reset_Menu() {
	var imgTurl;
	if(document.images) {
  		imgTurl = 'homeimages/rollover_default.gif'; 
   		document.textroll.src=imgTurl;	
	}
}

function reset_InternalMenu(imgRurl) {
	if(document.images) {
   		document.forsyte_nav.src=imgRurl;
	}
}


function off_nav(thisNav, imgName) {
	var objStr,obj, imgRurl, imgTurl;
	if(document.images) {
		if (thisNav == 'm') {  
	  		objStr = 'document.m_' + imgName;
      		obj = eval(objStr);      
      		imgRurl = 'homeimages/forsyte_' + imgName + '.gif';
      		obj.src = imgRurl;
      		timeout_ForsyteId = setTimeout("reset_Menu()",10);      		
      		} 
      	else if (thisNav == 'm_ei') { 
 	  		objStr = 'document.m_' + imgName;
      		obj = eval(objStr);      
      		imgRurl = 'homeimages/forsyte_' + imgName + '.gif';
      		obj.src = imgRurl;
      		timeout_ForsyteId = setTimeout("reset_Menu()",10);      		
      		}  
      	else if (thisNav == 'f') { 
 	  		objStr = 'document.f_' + imgName;
      		obj = eval(objStr);      
      		imgRurl = 'homeimages/feature_' + imgName + '.gif';
      		obj.src = imgRurl;
      		timeout_ForsyteId = setTimeout("reset_Menu()",10);    
      		}  
      	else if (thisNav == 'i') { 
      		imgRurl = 'images/forsyte_intrnl_' + imgName + '.gif';
      		timeout_ForsyteInternalId = setTimeout("reset_InternalMenu(\"" + imgRurl + "\")",10); 
      		}
      	else if (thisNav == 'ei') { 
	  		objStr = 'document.' + imgName + '_s';
      		obj = eval(objStr);
      		imgTurl = 'images/default_descrip.gif';      
      		imgRurl = 'images/' + imgName + '_square.gif';
      		document.descrip.src=imgTurl;
      		obj.src = imgRurl;  
      		} 	     		     
	}
}

function on_nav(thisNav, imgName) {
	var objStr,obj, imgRurl, imgTurl;
	if(document.images) {
		if (thisNav == 'm') {
			clearTimeout(timeout_ForsyteId);
	  		objStr = 'document.m_' + imgName;
      		obj = eval(objStr);
      		imgTurl = 'homeimages/forsyte_' + imgName + '_text.gif';      
      		imgRurl = 'homeimages/forsyte_' + imgName + '_over.gif';
      		document.textroll.src=imgTurl;
      		obj.src = imgRurl;      		
      		}
       	else if (thisNav == 'm_ei') {
      		clearTimeout(timeout_ForsyteId);
      		objStr = 'document.m_' + imgName;
      		obj = eval(objStr);
      		imgTurl = 'homeimages/rollover_default.gif';      
      		imgRurl = 'homeimages/forsyte_' + imgName + '_over.gif';  
      		document.textroll.src=imgTurl;
      		obj.src = imgRurl;
      		}
     	else if (thisNav == 'f') {
      		clearTimeout(timeout_ForsyteId);
      		objStr = 'document.f_' + imgName;
      		obj = eval(objStr);
      		imgTurl = 'homeimages/feature_' + imgName + '_text.gif';
      		imgRurl = 'homeimages/feature_' + imgName + '_over.gif';  
      		document.textroll.src=imgTurl;
      		obj.src = imgRurl;
      		}
      	else if (thisNav == 'i') { 
      		clearTimeout(timeout_ForsyteInternalId);
      		imgRurl = 'images/forsyte_intrnl_' + imgName + '.gif';
      		document.forsyte_nav.src=imgRurl;
      		}
       	else if (thisNav == 'ei') {
       		document.galsworthy_s.src="images/galsworthy_square.gif";
       		document.lewis_s.src="images/lewis_square.gif";
       		document.saga_s.src="images/saga_square.gif";
	  		objStr = 'document.' + imgName + '_s';
      		obj = eval(objStr);
      		imgTurl = 'images/' + imgName + '_descrip.gif';      
      		imgRurl = 'images/' + imgName + '_square_over.gif';
      		document.descrip.src=imgTurl;
      		obj.src = imgRurl;  
      		} 
       	else if (thisNav == 'ei_off') {
       		document.galsworthy_s.src="images/galsworthy_square.gif";
       		document.lewis_s.src="images/lewis_square.gif";
       		document.saga_s.src="images/saga_square.gif";
	  		objStr = 'document.' + imgName + '_s';
      		obj = eval(objStr);
      		imgTurl = 'images/default_descrip.gif';      
      		imgRurl = 'images/' + imgName + '_square_over.gif';
      		document.descrip.src=imgTurl;
      		obj.src = imgRurl;  
      		}          		       		
	}
}

