// <![CDATA[
			
/* --------------------------------------------------------------------- */
/* MouseOver */
/* --------------------------------------------------------------------- */
function MouseOver() {
	//setting
	var KeyName = 'mouseover';
	var KeyName2 = 'mouseoverClick';
	var AddOn = '_on';
	var AddOn2 = '_ck';
	//move
	var ChangeSrc;
	var ChangeSrc2;
	var overImages = document.getElementsByTagName('img');
	var imgPreLoad = new Array();
	
	for (var i = 0; i < overImages.length; i++) {
		if (overImages[i].className == KeyName || overImages[i].className == KeyName2) {
			var temp = overImages[i];
			var src = temp.src;
			var FileType = src.substring(src.lastIndexOf('.'));
			var name = src.substring(0,src.length - FileType.length);
			var overSrc = name + AddOn + FileType;
			overImages[i].setAttribute('overSrc', overSrc);
			//preload
			imgPreLoad[i] = new Image();
			imgPreLoad[i].src = overSrc;
			//action
			overImages[i].onmouseover = function() {
				ChangeSrc = this.getAttribute('src');
				this.setAttribute('src', this.getAttribute('overSrc'));
			}	
			overImages[i].onmouseout = function() {
				if (!ChangeSrc) ChangeSrc = this.getAttribute('src').replace(AddOn+FileType, FileType);
				this.setAttribute('src', ChangeSrc);
			}
			
			if (overImages[i].className == KeyName2) {
				var clickSrc = name + AddOn2 + FileType;
				overImages[i].setAttribute('clickSrc', clickSrc);
				//
				overImages[i].onmousedown = function() {
					ChangeSrc2 = this.getAttribute('src');
					this.setAttribute('src', this.getAttribute('clickSrc'));
				}
				overImages[i].onmouseup = function() {
					if (!ChangeSrc2) ChangeSrc2 = this.getAttribute('src').replace(AddOn2+FileType, AddOn+FileType);
					this.setAttribute('src', ChangeSrc2);
				}
			}
			
		}
	}
}


/* --------------------------------------------------------------------- */
/* pageMove */
/* --------------------------------------------------------------------- */

var ScrW;
function pageMove(){
	//IE6 check
	/*
	if (navigator.userAgent.indexOf("WIN") <= 0 && typeof document.body.style.maxHeight != "undefined") {
		//
	} else {
		document.all("pageTop").style.display = "none";
	}
	*/
	//
	if(window.innerWidth){
		ScrW = window.innerWidth;
	}else if(document.documentElement && document.documentElement.clientWidth){
		ScrW = document.documentElement.clientWidth;
	}else if(document.body && document.body.clientWidth){
		ScrW = document.body.clientWidth;
	}
	//
	if(ScrW < 1040){
		if(document.all){
			document.all("pageTop").style.display = "none";
		}else if(navigator.userAgent.indexOf("Gecko")!=-1){
			document.getElementById("pageTop").style.display = "none";
		}
	}else{
		if(document.all){
			document.all("pageTop").style.display = "block";
		}else if(navigator.userAgent.indexOf("Gecko")!=-1){
			document.getElementById("pageTop").style.display = "block";
		}
	}
}




/* --------------------------------------------------------------------- */
/* scriptFunction */
/* --------------------------------------------------------------------- */

window.onload = function() {
   pageMove();
   pictChange();
   MouseOver();
}
window.onresize = pageMove;

// ]]>
