//*************** G K *************//

function mouseMove(ev)
{
 ev = ev || window.event ;//window.event
  mousePos = mouseCoords(ev);
  
  ChangeCur();
  var xxx = document.getElementById('xxx');
  var yyy = document.getElementById('yyy');
  if(xxx!=null)xxx.value = mousePos.x;
  if(yyy!=null)yyy.value = mousePos.y;
}

function mouseCoords(ev)
{
 if(ev.pageX || ev.pageY){
   return {x:ev.pageX, y:ev.pageY};
 }
 return {
     x:ev.clientX + document.body.scrollLeft - document.body.clientLeft,
     y:ev.clientY + document.body.scrollTop - document.body.clientTop
 };
}

var bCurLeft=3; //初始不是左也不是右,为左，2为右
function ChangeCur()
{
	
	if(mousePos.x < 520 && bCurLeft!=1)
	{
		bCurLeft = 1;
		var div = document.getElementById('box');
		div.style.cursor="../cursors/left.cur";
	}
	else if(mousePos.x > 520 && bCurLeft!=2)
	{
		bCurLeft = 2;
		var div = document.getElementById('box');
		div.style.cursor="../cursors/right.cur";
	}
}

function LButtonDown(PathLeft,PathRight)
{
	if(mousePos.x < 520)
	{
		window.location.href=(PathLeft);
	}
	else
	{
		window.location.href=(PathRight);
	}		
}

