
var ccm_uiLoaded=false;var ccm_siteActivated=true;var ccm_animEffects=false;ccm_parseJSON=function(resp,onNoError){if(resp.error){alert(resp.message);}else{onNoError();}}
ccm_deactivateSite=function(onDone){if(ccm_siteActivated==false){return false;}
if($("#ccm-overlay").length<1){$(document.body).append('<div id="ccm-overlay"></div>');}
$("embed,object").each(function(){$(this).attr('ccm-style-old-visibility',$(this).css('visibility'));$(this).css('visibility','hidden');});if(ccm_animEffects){$("#ccm-overlay").fadeIn(100);}else{$("#ccm-overlay").show();}
ccm_siteActivated=false;if(typeof onDone=='function'){onDone();}}
ccm_activateSite=function(){if(ccm_animEffects){$("#ccm-overlay").fadeOut(100);}else{$("#ccm-overlay").hide();}
$("embed,object").each(function(){$(this).css('visibility',$(this).attr('ccm-style-old-visibility'));});ccm_siteActivated=true;ccm_topPaneDeactivated=false;}
ccm_addHeaderItem=function(item,type){if(type=='CSS'){if(!($('head').children('link[href*='+item+']').length)){$('head').append('<link rel="stylesheet" type="text/css" href="'+item+'?ts='+new Date().getTime()+'" />');}}else if(type=='JAVASCRIPT'){if(!($('head').children('script[src*='+item+']').length)){$('head').append('<script type="text/javascript" src="'+item+'?ts='+new Date().getTime()+'"></script>');}}}
ccm_disableLinks=function(){td=document.createElement("DIV");td.style.position="absolute";td.style.top="0px";td.style.left="0px";td.style.width="100%";td.style.height="100%";td.style.zIndex="1000";document.body.appendChild(td);};;var ccmSlideShowHelper1123={bID:1123,imgNum:0,init:function(){this.displayWrap=$('#ccm-SlideshowBlock-display'+this.bID);if(this.imgInfos.length==0){return false;}
var maxHeight=0;for(var i=0;i<this.imgInfos.length;i++){this.addImg(i);if(maxHeight==0||this.imgInfos[i].imgHeight>maxHeight)
maxHeight=this.imgInfos[i].imgHeight;}
this.displayWrap.css('height',maxHeight);for(var i=0;i<this.imgInfos.length;i++){if(this.imgInfos[i].imgHeight<maxHeight){var t=((maxHeight-this.imgInfos[i].imgHeight)/2);this.imgEls[i].css('top',t);}}
this.nextImg();},nextImg:function(){if(this.imgNum>=this.imgInfos.length)this.imgNum=0;this.imgEls[this.imgNum].css('opacity',0);this.imgEls[this.imgNum].css('display','block');this.imgEls[this.imgNum].animate({opacity:1},this.imgInfos[this.imgNum].fadeDuration*1000,'',function(){ccmSlideShowHelper1123.preparefadeOut()});var prevNum=this.imgNum-1;if(prevNum<0)prevNum=this.imgInfos.length-1;if(this.imgInfos.length==1)return;this.imgEls[prevNum].animate({opacity:0},this.imgInfos[this.imgNum].fadeDuration*800,function(){this.style.zIndex=1;});},preparefadeOut:function(){if(this.imgInfos.length==1)return;var milisecDuration=parseInt(this.imgInfos[this.imgNum].duration)*1000;this.imgEls[this.imgNum].css('z-index',2);setTimeout('ccmSlideShowHelper'+1123+'.nextImg();',milisecDuration);this.imgNum++;},maxHeight:0,imgEls:[],addImg:function(num){var el=document.createElement('div');el.id="slideImgWrap"+num;el.className="slideImgWrap";if(this.imgInfos[num].fullFilePath.length>0)
imgURL=this.imgInfos[num].fullFilePath;else imgURL='/files/'+this.imgInfos[num].fileName;el.innerHTML='<div style="height:'+this.imgInfos[num].imgHeight+'px; background:url(\''+escape(imgURL)+'\') center no-repeat">&nbsp;</div>';el.style.display='none';this.displayWrap.append(el);var jqEl=$(el);this.imgEls.push(jqEl);},imgClick:function(linkURL){},imgInfos:[{fileName:"3.jpg",fullFilePath:"/files/9112/9420/6271/3.jpg",duration:5,fadeDuration:2,url:"/files/9112/9420/6271/3.jpg",groupSet:0,imgHeight:410},{fileName:"5.jpg",fullFilePath:"/files/3612/9420/6275/5.jpg",duration:5,fadeDuration:2,url:"/files/3612/9420/6275/5.jpg",groupSet:0,imgHeight:410},{fileName:"1.jpg",fullFilePath:"/files/5112/9420/6247/1.jpg",duration:5,fadeDuration:2,url:"/files/5112/9420/6247/1.jpg",groupSet:0,imgHeight:410},{fileName:"8.jpg",fullFilePath:"/files/1612/9420/6288/8.jpg",duration:5,fadeDuration:2,url:"/files/1612/9420/6288/8.jpg",groupSet:0,imgHeight:410},{fileName:"6.jpg",fullFilePath:"/files/9012/9420/6281/6.jpg",duration:5,fadeDuration:2,url:"/files/9012/9420/6281/6.jpg",groupSet:0,imgHeight:410},{fileName:"slide4.jpg",fullFilePath:"/files/2212/9347/7320/slide4.jpg",duration:5,fadeDuration:2,url:"/files/2212/9347/7320/slide4.jpg",groupSet:0,imgHeight:410},{fileName:"4.jpg",fullFilePath:"/files/6112/9420/6274/4.jpg",duration:5,fadeDuration:2,url:"/files/6112/9420/6274/4.jpg",groupSet:0,imgHeight:410},{fileName:"7.jpg",fullFilePath:"/files/9212/9420/6284/7.jpg",duration:5,fadeDuration:2,url:"/files/9212/9420/6284/7.jpg",groupSet:0,imgHeight:410},{fileName:"2.jpg",fullFilePath:"/files/7912/9420/6269/2.jpg",duration:5,fadeDuration:2,url:"/files/7912/9420/6269/2.jpg",groupSet:0,imgHeight:410}]}
$(function(){ccmSlideShowHelper1123.init();});var flashvars={};flashvars.allowFullscreen=1;flashvars.autoPlay=0;flashvars.backgroundColor="#000000";flashvars.editMode=0;flashvars.posterFrame="/files/thumbnails/level3/7412/8472/2446/tkd.jpg";flashvars.videoPath="/files/7412/8472/2446/tkd.mp4";var parameters={};parameters.allowFullScreen=true;parameters.wmode="opaque";swfobject.embedSWF("/packages/flash_video/blocks/flash_video/assets/VideoPlayer.swf","flash_video_710","270","180","9.0.28",null,flashvars,parameters);var ccmSlideShowHelper1088={bID:1088,imgNum:0,init:function(){this.displayWrap=$('#ccm-SlideshowBlock-display'+this.bID);if(this.imgInfos.length==0){return false;}
var maxHeight=0;for(var i=0;i<this.imgInfos.length;i++){this.addImg(i);if(maxHeight==0||this.imgInfos[i].imgHeight>maxHeight)
maxHeight=this.imgInfos[i].imgHeight;}
this.displayWrap.css('height',maxHeight);for(var i=0;i<this.imgInfos.length;i++){if(this.imgInfos[i].imgHeight<maxHeight){var t=((maxHeight-this.imgInfos[i].imgHeight)/2);this.imgEls[i].css('top',t);}}
this.nextImg();},nextImg:function(){if(this.imgNum>=this.imgInfos.length)this.imgNum=0;this.imgEls[this.imgNum].css('opacity',0);this.imgEls[this.imgNum].css('display','block');this.imgEls[this.imgNum].animate({opacity:1},this.imgInfos[this.imgNum].fadeDuration*1000,'',function(){ccmSlideShowHelper1088.preparefadeOut()});var prevNum=this.imgNum-1;if(prevNum<0)prevNum=this.imgInfos.length-1;if(this.imgInfos.length==1)return;this.imgEls[prevNum].animate({opacity:0},this.imgInfos[this.imgNum].fadeDuration*800,function(){this.style.zIndex=1;});},preparefadeOut:function(){if(this.imgInfos.length==1)return;var milisecDuration=parseInt(this.imgInfos[this.imgNum].duration)*1000;this.imgEls[this.imgNum].css('z-index',2);setTimeout('ccmSlideShowHelper'+1088+'.nextImg();',milisecDuration);this.imgNum++;},maxHeight:0,imgEls:[],addImg:function(num){var el=document.createElement('div');el.id="slideImgWrap"+num;el.className="slideImgWrap";if(this.imgInfos[num].fullFilePath.length>0)
imgURL=this.imgInfos[num].fullFilePath;else imgURL='/files/'+this.imgInfos[num].fileName;el.innerHTML='<div style="height:'+this.imgInfos[num].imgHeight+'px; background:url(\''+escape(imgURL)+'\') center no-repeat">&nbsp;</div>';el.style.display='none';this.displayWrap.append(el);var jqEl=$(el);this.imgEls.push(jqEl);},imgClick:function(linkURL){},imgInfos:[{fileName:"gallery1.jpg",fullFilePath:"/files/5912/9288/6288/gallery1.jpg",duration:7,fadeDuration:2,url:"",groupSet:0,imgHeight:180},{fileName:"gallery2.jpg",fullFilePath:"/files/7512/9288/6307/gallery2.jpg",duration:7,fadeDuration:2,url:"",groupSet:0,imgHeight:180},{fileName:"gallery3.jpg",fullFilePath:"/files/2912/9288/6322/gallery3.jpg",duration:7,fadeDuration:2,url:"",groupSet:0,imgHeight:180}]}
$(function(){ccmSlideShowHelper1088.init();});
