	function P80_moveBy(dx,dy)
	{
		x=this.x+dx;
		y=this.y+dy;
		if (this.isStopSet) {
			if (x < this.leftStop)
				x=this.leftStop;
			if (x > this.rightStop)
				x=this.rightStop;
			if (y < this.topStop)
				y=this.topStop;
			if (y > this.bottomStop)
				y=this.bottomStop;
		}
		this.x=x;
		this.y=y;
		this.movable.left=this.x+"px";
		this.movable.top=this.y+"px";
	}

	function P80_moveTo(x,y)
	{
		if (this.isStopSet) {
			if (x < this.leftStop)
				x=this.leftStop;
			if (x > this.rightStop)
				x=this.rightStop;
			if (y < this.topStop)
				y=this.topStop;
			if (y > this.bottomStop)
				y=this.bottomStop;
		}
		this.x=x;
		this.y=y;
		this.movable.left=this.x+"px";
		this.movable.top=this.y+"px"; 
	}

	function P80_moveToX(x)
	{
		if (this.isStopSet) {
			if (x < this.leftStop)
				x=this.leftStop;
			if (x > this.rightStop)
				x=this.rightStop;
		}
		this.x=x;
		this.movable.left=this.x+"px";
	}

	function P80_moveToY(x,y)
	{
		if (this.isStopSet) {
			if (y < this.topStop)
				y=this.topStop;
			if (y > this.bottomStop)
				y=this.bottomStop;
		}
		this.y=y;
		this.movable.top=this.y+"px"; 
	}

	function P80_Movable_setStop(left,top,right,bottom)
	{
		this.isStopSet=true;
		this.leftStop=left;
		this.topStop=top;
		this.rightStop=right;
		this.bottomStop=bottom;
	}

	function P80_Movable_unsetStop(left,top,right,bottom)
	{
		this.isStopSet=false;
		this.leftStop=0;
		this.topStop=0;
		this.rightStop=0;
		this.bottomStop=0;
	}

	function P80_Movable_hide()
	{
		this.isHidden=true;
		this.movable.visibility="hidden";
	}

	function P80_Movable_show()
	{
		this.isHidden=false;
		this.movable.visibility="visible";
	}

	function P80_Movable(elementid)
	{
		if (navigator.appName == "Netscape") {
			if (navigator.appVersion.charAt(0) == "5")
			{
				this.movable=document.getElementById(elementid).style;
			}
			else
			{	var temp;
				this.movable=document[elementid];
			}
		} else 
			this.movable=document.all[elementid].style;

		if (this.movable.left.length == 0)
			this.x=0;
		else
			this.x=parseInt(this.movable.left,10);
		if (this.movable.top.length == 0)
			this.y=0;
		else
			this.y=parseInt(this.movable.top,10);
		this.isHidden=(this.movable.visibility == "hidden");
		this.isStopSet=false;
		this.stopLeft=0;
		this.stopRight=0;
		this.stopTop=0;
		this.stopBottom=0;
		this.setStop=P80_Movable_setStop;
		this.unsetStop=P80_Movable_unsetStop;
		this.moveBy=P80_moveBy;
		this.moveTo=P80_moveTo;
		this.moveToX=P80_moveToX;
		this.moveToY=P80_moveToY;
		this.show=P80_Movable_show;
		this.hide=P80_Movable_hide;
	}
