function GetScrollBarWidth()
{
	try
	{
		var E = document.createElement("DIV");
		E.id								= "ScrolBarWidthTester";
		E.style.width				= 100;
		E.style.height			= 100;
		E.style.overflow		= "scroll";
		E.style.position		= "absolute";
		E.style.visibility	= "hidden";
		E.style.top					= "0";
		E.style.left				= "0";
		
		document.body.appendChild( E );
		
		ScrollBarWidth = document.all['ScrolBarWidthTester'].offsetWidth - document.all['ScrolBarWidthTester'].clientWidth;
		
		document.body.removeChild( E );
		delete E;
	}
	catch ( ex )
	{
		ScrollBarWidth = 0;
	}
	
	return ScrollBarWidth;
} // END function GetScrollBarWidth()


/* (c) Konrad */
function show(co, wi, he)
{
  wii = wi + 40;
  hee = he + 20;
	
  if ( screen.availHeight - 50 < hee )
	  hee = screen.availHeight - 50;
	
  if ( screen.availWidth < wii )
	{
	  wii = screen.availWidth - 30;
		hee += 10;
	}
	
  if ( okno && !okno.closed )
	  okno.close();
	
  xx = ( screen.availHeight - hee ) / 2 - 10;
  yy = ( screen.availWidth - wii ) / 2;
  okno = window.open( 'about:blank', '', 'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,fullscreen=no,channelmode=no,height=' + hee + ',width=' + wii + ',top=' + xx + ',left=' + yy );
  okno.document.write( '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><HTML><HEAD><META CONTENT="text/html; charset=iso-8859-2" HTTP-EQUIV=Content-Type><META NAME="Author" CONTENT="www.venti.com.pl"><TITLE>Skamex</TITLE></HEAD><BODY style="background: #fff; margin: 0px; padding: 0px"><TABLE WIDTH="100%" height="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0"><tr><td style="padding:5px 10px; text-align: center; vertical-align: middle"><a onfocus="blur()" href="javascript:self.close()"><img src="'+co+'" width="'+wi+'" height="'+he+'" style="border: 1px solid #ddd"></a></td></tr></TABLE></BODY></HTML>' );
}

/* (c) Bartek */
function BlurAll()
{
	var links = document.getElementsByTagName('a');
	for ( var i = 0; i < links.length; i++ )
  	links[i].onfocus = BlurMe;
}

function BlurMe()
{
	this.blur();
}

//funkcje do podmiany zdjec
function fon(n){document.images[n].src='grafika/'+n+'.gif';}
function foff(n){document.images[n].src='grafika/'+n+'1.gif';}

//funkcja do wyswietlania popupu
var okno='';
function popup(wi,he,uerel,alignx,aligny,scrol)
{
	if(okno &&!okno.closed){okno.close()}
	if(wi=='100%'){wi=screen.availWidth-30}
	if(he=='100%'){he=screen.availHeight-0}
	if(alignx=='left'){xx=0}
	else if(alignx=='right'){xx=(screen.availWidth-wi)-10}
	else{xx=(screen.availWidth-wi)/2}
	if(aligny=='top'){yy=0}
	else if(aligny=='bottom'){yy=(screen.availHeight-he)}
	else{yy=(screen.availHeight-he)/2}
	okno=window.open(uerel, '_blank', 'scrollbars='+scrol+',height='+he+',width='+wi+',top='+yy+',left='+xx);
}

/*ladowanie do casch-u zdjec
foto=new Array('pl','en');
menuA=new Array();menuB=new Array();
for(n=0;n<foto.length;n++){
	menuA[n]=new Image();
	menuA[n].src='grafika/'+foto[n]+'.gif';
	menuB[n]=new Image();
	menuB[n].src='grafika/'+foto[n]+'1.gif';
}
*/
