var xx;
//var growthByStep = new Array(50, 55, 60, 65, 70, 75, 80, 85, 90, 95, 100);
var growthByStep = new Array(50, 60, 70, 80, 90, 100);
var stepCount = growthByStep.length;
var realWidth = 135;
var realHeight = 185;
var realLeft = 17;
var realTop = 48;
var stepNo = 0;
var dLeft=0;
var dTop=0;

function over_img(id){
	document.getElementById(id+'_div').style.display='block';
	document.getElementById('stick_'+id).style.display='none';
  showImage(id);
}

function showImage(id){
	img=document.getElementById(id+'_b');
	if ((stepCount > stepNo + 1)){
	document.getElementById(id+'_b').style.display='block';
		stepNo++;
    img.width = realWidth * growthByStep[stepNo] / 100;
    dLeft=realWidth*growthByStep[stepNo]/200-realWidth*growthByStep[stepNo-1]/200;
    dTop=realHeight*growthByStep[stepNo]/100-realHeight*growthByStep[stepNo-1]/100;
    img.height = realHeight * growthByStep[stepNo] / 100;
		img.style.marginLeft=img.style.marginLeft.substring(0, img.style.marginLeft.length-2)-dLeft+'px';
		img.style.marginTop=img.style.marginTop.substring(0, img.style.marginTop.length-2)-dTop+'px';
  	xx=setTimeout('showImage("'+id+'")', 30);
//		img.style.opacity = stepNo/10+0.5;
//		img.style.filter = 'alpha(opacity=' + ((stepNo+1)*100/stepCount) + ')';
	}
}

function out_img(id){

	img=document.getElementById(id+'_b');
	clearTimeout(xx);
	img.style.display='none';
	document.getElementById(id+'_div').style.display='none';
	document.getElementById('stick_'+id).style.display='block';
	img.style.marginLeft=realLeft+'px';
	img.style.marginTop=realTop+'px';
	stepNo = 0;
	dLeft=0;
	dTop=0;
}