function $(str){return document.getElementById(str)}
var simg = new function (){
	this.imgwidth_active = 500;
	this.imgwidth_unactive = 50;
	this.active = 0;
	this.init = 50;

	this.slide_d = function (id){
		var obj = $("img"+id);
		if (id<=this.active){
			var maxwidth = this.imgwidth_unactive * (id - 1);
			if (parseFloat(obj.style.left) > maxwidth){
				obj.style.left = parseFloat(obj.style.left) - this.init + "px";
				setTimeout("simg.slide_d ('"+id+"')", 1);
			}
		}else{
			var maxwidth = this.imgwidth_active + (this.imgwidth_unactive * (id - 2));
			if (parseFloat(obj.style.left) < maxwidth){
				obj.style.left = parseFloat(obj.style.left) + this.init + "px";
				setTimeout("simg.slide_d ('"+id+"')", 1);
			}
		}
		
	};

	this.slide = function (active){
		this.active = active;
		this.slide_d(1);
		this.slide_d(2);
		this.slide_d(3);
		this.slide_d(4);
		this.slide_d(5);
	};
}
function FloorPlan(rm,rmname,w,h){window.open("../accom/"+rm+".html?rmname="+rmname+"","","toolbar=0 width="+w+" height="+h+"");}
function loadMap(map,mapname){window.open("../location/"+map+".html?mapname="+mapname+"","","scrollbars=yes resizable=yes width=720px,height=500px");}








