function show_selector_menu2(select_menu_id2){
	var select_menu2 = $(select_menu_id2);
	if( select_menu2.style.visibility == "inherit"){
		var menu_content2 = select_menu2.firstChild;
		if(navigator.userAgent.indexOf('MSIE')>=0){
			menu_content2.style.marginBottom = "0";
			var select_menu_height2 = select_menu2.offsetHeight;
			var timer2 = setInterval(
								function(){
									var marginb2 = parseInt(menu_content2.style.marginBottom);
									if( marginb2<=parseInt("-"+select_menu_height2) ){
										menu_content2.style.marginBottom = "0";
										select_menu2.style.visibility = "hidden";
										clearInterval(timer2);	
									}else{
										menu_content2.style.marginBottom = (marginb2-20)+"px";
									}
								}
								,1);
		}else{
			select_menu2.style.visibility = "hidden";
		}
	}else{
		var menu_content2 = select_menu2.firstChild;
		if(navigator.userAgent.indexOf('MSIE')>=0){
			menu_content2.style.marginBottom = "-"+ select_menu2.offsetHeight+"px";
			var timer2 = setInterval(
								function(){
									var marginb2 = parseInt(menu_content2.style.marginBottom);
									if(marginb2>=0){
										menu_content2.style.marginBottom = "0";
										clearInterval(timer2);	
									}else{
										menu_content2.style.marginBottom = (marginb2+20)+"px";
									}
								}
								,1);
		}
		selector_is_clicked[select_menu_id2] = true;
		select_menu2.style.visibility = "inherit";
	}
}

var showImageIndex2 = -1;
var imageTimer2;
function showImage2(imageIndex2)
{
	var flash_img_div2 = document.getElementById("flash_img2");
	var flash_title2 = document.getElementById("flash_title2");	
	
	if(imageIndex2>fImgs2.length-1){
		imageIndex2 = 0;
	}
	
	if(!fImgs2[imageIndex2] || imageIndex2==showImageIndex2)
		return false;	
	var imgId2 = "__fImg2"+imageIndex2;
	flash_img_div2.filters && flash_img_div2.filters[0].Apply();
	for(i=0; i<flash_img_div2.childNodes.length; i++){
		flash_img_div2.childNodes[i].style.display = "none";
	}
	if( document.getElementById(imgId2) ){
		var imga2 = document.getElementById(imgId2);
		imga2.style.display = "block";
		if(imga2.tagName=="OBJECT"){
			imga2.rewind();
			imga2.Play();
		}
	}else{
		var pos = fImgs2[imageIndex2].img2.lastIndexOf(".");
		if( fImgs2[imageIndex2].img2.substr(pos+1).substr(0,3).toLowerCase()=="swf" ){
			flash_img_div2.innerHTML += '\
				<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="250" height="150" id="'+imgId2+'">\
					<param name="movie" value="'+fImgs2[imageIndex2].img2+'" />\
					<param name="quality" value="high" />\
					<embed src="'+fImgs2[imageIndex].img2+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="250" height="150"></embed>\
				</object>';

		}else{
			var img2 = new Image();
			img2.border = "0";
			img2.src = fImgs2[imageIndex2].img2;
			img2.width = "250";
			img2.height = "150";
			var a = document.createElement("a");
			a.href = fImgs2[imageIndex2].href;
			a.target = "_blank";
			a.id = imgId2;
			a.appendChild(img2);
			flash_img_div2.appendChild(a);
		}
	}
	flash_img_div2.filters && flash_img_div2.filters[0].Play();
	var flash_show_ctl_msg2 = document.getElementById("flash_show_ctl_msg");
	flash_show_ctl_msg2.filters && flash_show_ctl_msg2.filters[0].Apply();
	flash_title2.href = fImgs2[imageIndex2].href;
	flash_title2.innerHTML = fImgs2[imageIndex2].title;
	flash_show_ctl_msg2.filters && flash_show_ctl_msg2.filters[0].Play();
	showImageIndex2 = imageIndex2;
	return true;
}
function imagePlay2()
{
	if(imageTimer2) return;
	if(showImageIndex2>=fImgs2.length-1){
		showImageIndex2 = -1;
	}
	showImage2(showImageIndex2+1);
	imageTimer2 = setInterval(function(){
					var stat2 = showImage2(showImageIndex2+1);
					if(!stat2){
						stop2();
					}	
				},3000);
}
function stop2(){
	clearInterval(imageTimer2);
	imageTimer2 = null;
}
function showNextImage2(){
	showImage2(showImageIndex2+1);
}
function showPrevImage2(){
	showImage2(showImageIndex2-1);
}