<!--

var DHTML = (document.getElementById || document.all || document.layers);

function getObj(name)
{
  if (document.getElementById)
  {
  	this.obj = document.getElementById(name);
	this.style = document.getElementById(name).style;
  }
  else if (document.all)
  {
	this.obj = document.all[name];
	this.style = document.all[name].style;
  }
  else if (document.layers)
  {
   	this.obj = document.layers[name];
   	this.style = document.layers[name];
  }
}

function invi(name,flag)
{
	if (!DHTML) return;
	var x = new getObj(name);
	x.style.visibility = (flag) ? 'hidden' : 'visible'
}

function coltd(name)
{
	if (!DHTML) return;
	if(name!='tdfirm') { var x = new getObj('tdfirm'); x.style.backgroundColor='#96A9AD'; }
	if(name!='tdoferta') { var x = new getObj('tdoferta'); x.style.backgroundColor='#96A9AD';}
	if(name!='tdportfolio') { var x = new getObj('tdportfolio'); x.style.backgroundColor='#96A9AD';}
	if(name!='tdreferencje') { var x = new getObj('tdreferencje'); x.style.backgroundColor='#96A9AD';}
	if(name!='tdkontakt') { var x = new getObj('tdkontakt'); x.style.backgroundColor='#96A9AD';}
}

var which=1
var ilosc=1
var galeria=''

function backward(g)
{

	if(which>1){
		which--
		if(which<10) document.all.photoslider.src="../"+g+"/"+g+".0"+which+".jpg"
		else document.all.photoslider.src="../"+g+"/"+g+"."+which+".jpg"
	} else {
		which=ilosc
		if(which<10) document.all.photoslider.src="../"+g+"/"+g+".0"+which+".jpg"
		else document.all.photoslider.src="../"+g+"/"+g+"."+which+".jpg"
	}

}

function forward(g)
{

	if(which<ilosc){
		which++
		if(which<10) document.all.photoslider.src="../"+g+"/"+g+".0"+which+".jpg"
		else document.all.photoslider.src="../"+g+"/"+g+"."+which+".jpg"
	} else {
		which=1
		document.all.photoslider.src="../"+g+"/"+g+".0"+which+".jpg"
	}
}

function start(g,i)
{
	which=1
	ilosc=i
	galeria=g
	document.all.photoslider.src="../"+g+"/"+g+".0"+which+".jpg"
}
//-->
