//OCMS CASE 202701 - THIS FUNCTION SOLVES THE PROBLEM WITH NAME.DLL
//DON'T DELETE!!!!
function ProcessImn()
{

}
/* This part defines the sIFR stuff */
$().ready(function(){
	if(typeof sIFR == "function"){
											
		
		bodyh1=named({
						sSelector:"body h1",
						sFlashSrc:"/asset/js/vagRounded.swf",
						sColor:"#756C63",
						sLinkColor:"#000000",
						sBgColor:"#FFFFFF",
						sHoverColor:"#CCCCCC",
						sFlashVars:"textalign=left",
						sWmode: "transparent",
						nPaddingTop:0, 
						nPaddingBottom:0
					});
		sIFR.replaceElement(bodyh1);
		
		homePageH2=named({
						sSelector:".homePage .hero h2",
						sFlashSrc:"/asset/js/vagRounded.swf",
						sColor:"#756C63",
						sLinkColor:"#000000",
						sBgColor:"#FFFFFF",
						sHoverColor:"#CCCCCC",
						sFlashVars:"textalign=left",
						sWmode: "transparent",
						nPaddingTop:0, 
						nPaddingBottom:0
					});
		sIFR.replaceElement(homePageH2);									
		
		// Add DSC
		homeH2=named({
						sSelector:".homePage #contentArea h2",
						sFlashSrc:"/asset/js/vagRounded.swf",
						sColor:"#756C63",
						sLinkColor:"#000000",
						sBgColor:"#FFFFFF",
						sHoverColor:"#CCCCCC",
						sFlashVars:"textalign=left",
						sWmode: "transparent",
						nPaddingTop:0, 
						nPaddingBottom:0
					});
		sIFR.replaceElement(homeH2);	

		textContainerH2=named({
						sSelector:".textContainer h2",
						sFlashSrc:"/asset/js/vagRounded.swf",
						sColor:"#756C63",
						sLinkColor:"#000000",
						sBgColor:"#FFFFFF",
						sHoverColor:"#CCCCCC",
						sFlashVars:"textalign=left",
						sWmode: "transparent",
						nPaddingTop:0, 
						nPaddingBottom:0
					});
		sIFR.replaceElement(textContainerH2)
											
		landingSubHeading=named({
						sSelector:".textContainer h3",
						sFlashSrc:"/asset/js/vagRounded.swf",
						sColor:"#756C63",
						sLinkColor:"#000000",
						sBgColor:"#FFFFFF",
						sHoverColor:"#CCCCCC",
						sFlashVars:"textalign=left",
						sWmode: "transparent",
						nPaddingTop:0, 
						nPaddingLeft:0,
						nPaddingBottom:0
					});
		sIFR.replaceElement(landingSubHeading);														
	};	
								
});


/* improving accessibility adding hover/focus capabilities to IE6 buttons */
$().ready(function(){	
	if($.browser.msie){	
		$("button").focus(function(){
								   	$(this).addClass("hover")}
						).blur(function(){
									$(this).removeClass("hover")
						}).hover(	function(){
								   	$(this).addClass("hover")},
							function(){
									$(this).removeClass("hover")}
						 )							
	}
							
});

/* initialize the Ajax handler */
$().ready(function(){
	Adecco.init();
	Partner.init();
	//Adecco.dynamicInputText();
	//Adecco.footerDropDownLinks();
	//Adecco.faqPanelsInit();
	//Adecco.miniPanelsInit();
});


/*************************
		Adecco Init
**************************/

	Adecco=
	{	
		//used by the firstPage / lastPage buttons	
		currentPage:1,		
		pagesCount:0,
		sortBy:null,
		newsCollection:null,
		currentNews:-1,
		rotatorHandler:null,
		
		init:function()
		{			
	            
			$(document.body).addClass("hasJs");
			
				$(document.body).addClass("hasJs");
				
				// defining the news rotator behaviours			
				Adecco.newsCollection=$(".jobTicker .jobTickerItem");
																	
				$(".jobTicker").mouseover(function()
				{
					clearInterval(Adecco.rotatorHandler);
				});
		                                            
				$(".jobTicker").mouseout(function()
				{
					startNews();
				});
				
				if ($(document.body).hasClass("homePage hasJs"))
				{
					newsAnimation();
					startNews();
				}
		}
	}


	// Rotating jobs news.	
	function startNews()
	{
		newsDuration=5000;
		
		if (Adecco.newsCollection.length>0)
		{
			Adecco.rotatorHandler=setInterval(newsAnimation,newsDuration)
		}		
	}


	function newsAnimation()
	{
		
		if(Adecco.currentNews>-1)
		{
			$(Adecco.newsCollection[Adecco.currentNews]).animate(
			{																						 
				opacity:0,
				fontSize:"0em",
				height:"0px",
				paddingBottom:"0px"
			},1000,"swing",function(){this.style.display="none"})
		}
		
		Adecco.currentNews++;
		if (Adecco.currentNews>Adecco.newsCollection.length-1) Adecco.currentNews=0;
		
		if (Adecco.newsCollection[Adecco.currentNews])
		{ // Add DSC
			$(Adecco.newsCollection[Adecco.currentNews]).css({opacity:0,fontSize:"0em",height:"0px",paddingBottom:"0px"})									
			
			Adecco.newsCollection[Adecco.currentNews].style.display="block";
			
			$(Adecco.newsCollection[Adecco.currentNews]).animate(
			{
				opacity:1,
				fontSize:"1em",
				height:"160px",
				paddingBottom:"10px"
			},1000,"swing",function(){this.style.filter=""})			
		} // End. Add DSC
	}

/*************************
	End. Adecco Init
**************************/

/*************************
		Partner Init
**************************/
	Partner =
	{
		currentPage:1,		
		pagesCount:0,
		sortBy:null,
		newsCollection:null,
		currentNews:-1,
		rotatorHandler:null,
		
		init:function()
		{		            
			$(document.body).addClass("hasJs");
				
			Partner.newsCollection=$(".partnerLogos .partnerLogosItem");																		
																	
			$(".partnerLogosNext").mouseover
			(
				function()
				{
					PartnerAnimation();
					StartPartners();
				}
			);
			
			$(".partnerLogosNext").mouseout(function()
			{
				clearInterval(Partner.rotatorHandler);
			});
		}
	}

	function PartnerAnimation()
	{
		
		if(Partner.currentNews>-1)
		{
			$(Partner.newsCollection[Partner.currentNews]).animate(
			{																						 
				opacity:0,
				fontSize:"0em",
				height:"0px",
				paddingBottom:"0px"
			},1000,"swing",function(){this.style.display="none"})
		}
		
		Partner.currentNews++;
		if (Partner.currentNews>Partner.newsCollection.length-1) Partner.currentNews=0;
		
		if (Partner.newsCollection[Partner.currentNews])
		{ // Add DSC
			$(Partner.newsCollection[Partner.currentNews]).css({opacity:0,fontSize:"0em",height:"0px",paddingBottom:"0px"})									
			
			Partner.newsCollection[Partner.currentNews].style.display="block";
			
			$(Partner.newsCollection[Partner.currentNews]).animate
			(
				{opacity:1, fontSize:"1em", height:"160px", paddingBottom:"10px"},
				1000,
				"swing",
				function()
				{
					this.style.filter=""
				}
			)			
			
		} // End. Add DSC
	}

	function StartPartners()
	{
		newsDuration=3000;
		
		if (Partner.newsCollection.length>0)
		{
			Partner.rotatorHandler=setInterval(PartnerAnimation,newsDuration)
		}		
	}

/*************************
	End. Partner Init
**************************/

/*************************
	Video WebPart
**************************/

	function VideoPopUp(URL, WidthPopUp, HeightPopUp)
	{
		
		if (WidthPopUp == "")
			WidthPopUp = "450";
			
		if (HeightPopUp == "")
			HeightPopUp = "400";
			
		var options = "width=" + WidthPopUp + " , height=" + HeightPopUp + " , toolbar=NO, location=NO, directories=NO, status=NO, menubar=NO, scrollbars=NO, resizable=NO, left=300, top=200";
		
		window.open("/CAPPages/VideoPopUp.aspx?VideoURL=" + URL + "&VideoWidth=" + WidthPopUp + "&VideoHeight=" + HeightPopUp, "VideoPopUp", options);				
	}
	
/*************************
	End. Video WebPart
**************************/