/********************************************/
/* BIBLIOTEKA Warstwa						*/
/* wersja 1.0          2002-09-20           */
/********************************************/
/* Autor: Robert Gędlek					    */
/********************************************/
var mouseX;
var mouseY;

function getMouseX(e)
	{
		browser = testBrowser();

		if(browser==1)
			mouseX = document.body.scrollLeft+event.clientX;
		else if(browser==2)
			mouseX = e.pageX;
		else
			mouseX =  e.pageX;

		return mouseX;
	}

function getMouseY(e)
	{
		browser = testBrowser();

		if(browser==1)
			mouseY = document.body.scrollLeft+event.clientY;
		else if(browser==2)
			mouseY = e.pageY;
		else
			mouseY =  e.pageY;

		return  mouseY;
	}

function testBrowser()
	{
		var nameBrowser;
		nameBrowser = navigator.appName;
		nameBrowser=nameBrowser.toLowerCase();

		NN=(document.layers)? true:false;
		IE=(document.all)? true:false;

		if(IE==NN && nameBrowser=='netscape')
			return i=2;
		else if(IE)
			return i=1;
		else
			return i=3;
	}

var pre=false;
m_about = new Image();
m_about_o = new Image();
m_team = new Image();
m_team_o = new Image();
m_about = new Image();
m_about_o = new Image();
m_servises = new Image();
m_servises_o = new Image();

m_how = new Image();
m_how_o = new Image();
m_why = new Image();
m_why_o = new Image();
m_contact = new Image();
m_contact_o = new Image();


m_pod1_1 = new Image();
m_pod1_1_o = new Image();
m_pod1_2 = new Image();
m_pod1_2_o = new Image();
m_pod1_3 = new Image();
m_pod1_3_o = new Image();

m_pod2_1 = new Image();
m_pod2_1_o = new Image();
m_pod2_2 = new Image();
m_pod2_2_o = new Image();
m_pod2_3 = new Image();
m_pod2_3_o = new Image();

m_pod3_1 = new Image();
m_pod3_1_o = new Image();
m_pod3_2 = new Image();
m_pod3_2_o = new Image();
m_pod3_3 = new Image();
m_pod3_3_o = new Image();
m_pod3_4 = new Image();
m_pod3_4_o = new Image();

function preLoad()
	{
			if (document.images) 
				{

					
					m_about_o.src ="menu/main_activ_01.gif";		
					m_about.src ="menu/main_pasiv_01.gif";
					m_team_o.src ="menu/main_activ_03.gif";		
					m_team.src ="menu/main_pasiv_03.gif";
					m_servises_o.src ="menu/main_activ_05.gif";		
					m_servises.src ="menu/main_pasiv_05.gif";

					m_how_o.src ="menu/main_activ_07.gif";		
					m_how.src ="menu/main_pasiv_07.gif";
					m_why_o.src ="menu/main_activ_09.gif";		
					m_why.src ="menu/main_pasiv_09.gif";
					m_contact_o.src ="menu/main_activ_11.gif";		
					m_contact.src ="menu/main_pasiv_11.gif";

					m_pod1_1 = "podmenu/so_activ_01.gif";	
					m_pod1_1_o = "podmenu/so_pasiv_01.gif";
					
					m_pod1_2 = "podmenu/so_activ_02.gif";	
					m_pod1_2_o = "podmenu/so_pasiv_02.gif";	
					m_pod1_3 = "podmenu/so_activ_03.gif";	
					m_pod1_3_o = "podmenu/so_pasiv_03.gif";

					m_pod2_1 = "podmenu/we_activ_01.gif";	
					m_pod2_1_o = "podmenu/we_pasiv_01.gif";
					m_pod2_2 = "podmenu/we_activ_02.gif";	
					m_pod2_2_o = "podmenu/we_pasiv_02.gif";	
					m_pod2_3 = "podmenu/we_activ_03.gif";	
					m_pod2_3_o = "podmenu/we_pasiv_03.gif";

					m_pod3_1 = "podmenu/et_activ_01.gif";	
					m_pod3_1_o = "podmenu/et_pasiv_01.gif";
					m_pod3_2 = "podmenu/et_activ_02.gif";	
					m_pod3_2_o = "podmenu/et_pasiv_02.gif";	
					m_pod3_3 = "podmenu/et_activ_03.gif";	
					m_pod3_3_o = "podmenu/et_pasiv_03.gif";
					m_pod3_4 = "podmenu/et_activ_04.gif";	
					m_pod3_4_o = "podmenu/et_pasiv_04.gif";
					


					pre=true;
				}
	}

function menu(one, two)
	{
		if (document.images && (pre == true))
		   {
				if(one)document.images[one].src=two.src;
			}
	}

function menu2(one, two)
	{
		if (document.images && (pre == true))
		   {
				
				var b=testBrowser();
				if(b!=3) document.images[one].src=two;
			}
	}
var t;
var ktoryObrazek=0;
function menuNS4(obiekt, ob1,ob2,ob3,ob4,whichW,whichO)
	{
		var b=testBrowser();
		if (document.images && (pre == true) && b==3)
		   {	
				if(ktoryObrazek!=whichO)
					{
						t='';
						if(whichW==1)//jasny 1
							{
								t='<table height="17" cellspacing="0" cellpadding="0" border="0" width="780" bgcolor="#DEDEDE"><tr background="img/DEDEDE.gif"><td valign="top" width="116" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="116" height="17" border=0></td><td valign="top" background="img/DEDEDE.gif" align="left" width="320"><a href="raising.html" onmouseover="menu2(15,m_pod1_1);  menuNS4(blok,m_pod1_1,m_pod1_2_o,m_pod1_3_o,null,1,1);" onmouseout="menu2(15,m_pod1_1_o);"><img src="'+ob1+ '" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"><a href="bussines.html"  onmouseover="menu2(17,m_pod1_2); menuNS4(blok,m_pod1_1_o,m_pod1_2,m_pod1_3_o,null,1,2);" onmouseout="menu2(17,m_pod1_2_o);"><img src="'+ob2+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"><a href="acq.html" onmouseover="menu2(19,m_pod1_3); menuNS4(blok,m_pod1_1_o,m_pod1_2_o,m_pod1_3,null,1,3);" onmouseout="menu2(19,m_pod1_3_o);"><img src="'+ob3+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"></td><td valign="top" width="1" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="1" height="17" border=0></td></tr></table>';
							}
						else if(whichW==2)//jasny 2
							{
								t='<table height="17" cellspacing="0" cellpadding="0" border="0" width="780"  bgcolor="#DEDEDE"><tr background="img/DEDEDE.gif"><td valign="top" width="206" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="206" height="17" border=0></td><td valign="top" background="img/DEDEDE.gif" align="left" width="419"><a href="strategic.html" onmouseover="menu2(23,m_pod2_1); menuNS4(blok1,m_pod2_1,m_pod2_2_o,m_pod2_3_o,null,2,4);" onmouseout="menu2(23,m_pod2_1_o);"><img src="'+ob1+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"><a href="professional.html"  onmouseover="menu2(25,m_pod2_2); menuNS4(blok1,m_pod2_1_o,m_pod2_2,m_pod2_3_o,null,2,5);" onmouseout="menu2(25,m_pod2_2_o);"><img src="'+ob2+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"><a href="references.html" onmouseover="menu2(27,m_pod2_3); menuNS4(blok1,m_pod2_1_o,m_pod2_2_o,m_pod2_3,null,2,6);" onmouseout="menu2(27,m_pod2_3_o);"><img src="'+ob3+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"></td><td valign="top" width="1" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="1" height="17" border=0></td></tr></table>';
							}
						else if(whichW==3)//jasny 3
							{
								t='<table height="17" cellspacing="0" cellpadding="0" border="0" width="780"  bgcolor="#DEDEDE"><tr background="img/DEDEDE.gif"><td valign="top" width="54" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="54" height="17" border=0></td><td valign="top" background="img/DEDEDE.gif" align="left" width="462"><a href="kyle.html" onmouseover="menu2(31,m_pod3_1); menuNS4(blok2,m_pod3_1,m_pod3_2_o,m_pod3_3_o,m_pod3_4_o,3,7);" onmouseout="menu2(31,m_pod3_1_o);"><img src="'+ob1+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"><a href="dcruz.html" onmouseover="menu2(33,m_pod3_2);  menuNS4(blok2,m_pod3_1_o,m_pod3_2,m_pod3_3_o,m_pod3_4_o,3,8);" onmouseout="menu2(33,m_pod3_2_o);"><img src="'+ob2+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"><a href="reznikove.html"  onmouseover="menu2(35,m_pod3_3);  menuNS4(blok2,m_pod3_1_o,m_pod3_2_o,m_pod3_3,m_pod3_4_o,3,9);" onmouseout="menu2(35,m_pod3_3_o);"><img src="'+ob3+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"><a href="spencer.html" onmouseover="menu2(37,m_pod3_4); menuNS4(blok2,m_pod3_1_o,m_pod3_2_o,m_pod3_3_o,m_pod3_4,3,10);" onmouseout="menu2(37,m_pod3_4_o);"><img src="'+ob4+'" height="16" border=0></a><img src="img/FFFFFF.gif" width="1" height="17" border="0"></td><td valign="top" width="1" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="1" height="17" border=0></td></tr></table>';
							}
						t = t + '<table height="17" cellspacing="0" cellpadding="0" border="0" width="780"><tr><td valign="top" width="1" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="1" height="1" border=0></td><td valign="top" width="778" bgcolor="white"><a href="#" onmouseover="blok.show(0); blok1.show(0); blok2.show(0);"><img src="img/FFFFFF.gif" width="778" height="17" border=0></a></td><td valign="top" width="1" background="img/DEDEDE.gif"><img src="img/DEDEDE.gif" width="1" height="1" border=0></td></tr></table>';

						obiekt.html(t)
								
					}
				ktoryObrazek=whichO;

			}
	}

function reloadPage(init) {

  if (init==true) with (navigator) 
          {
                if ((appName=="Netscape")&&(parseInt(appVersion)==4)) 
					{
                        blok.html('');
						blok1.html('');
						blok2.html('');
						location.reload();
					}
        }
}

var wys_str;
var sze_str;

browser = testBrowser();

	function obrazek()
		{
			if ((browser==2) || (browser==1))
				{
					wys_str=parseInt(document.doc0.y);
					sze_str=document.images.doc0.src;
					alert(sze_str);
					
				}
			else if (browser==3)
				{
					wys_str= document.doc0.y;
					sze_str= document.doc0.x;
					alert(sze_str);
				}
		}

	function  parametryStrony()
		{
		   if ((browser==3))
				{
					sze_str=(window.innerWidth - 8);
					wys_str=(window.innerHeight - 8);
				}
		   else if((browser==2))
				{
					if(window.innerWidth==1024 || window.innerWidth==800)
						{
							sze_str=(window.innerWidth-16);
							wys_str=(window.innerHeight-16);
						}
					else
						{
							sze_str=(window.innerWidth);
							wys_str=(window.innerHeight);
						}
				}
		   else if((browser==1))
				{
					sze_str=(document.body.clientWidth);
					wys_str=(document.body.clientHeight);
				}
		}

	function polozenieDiv()
		{
			parametryStrony();
			blok.left(((sze_str-780)/2));
			blok1.left(((sze_str-780)/2));
			blok2.left(((sze_str-780)/2));
			stronaZaladowana=true;
		}

	function ukryjWarstwe(which)//roznica w ukrywaniu ns4 i reszty
		{
				if(browser==3 && which==1) setTimeout('blok.show(0)', 99000);	
				else if(browser==3 && which==2) setTimeout('blok1.show(0)', 99000);	
				else if(browser==3 && which==3) setTimeout('blok2.show(0)', 99000);
				else{blok.show(0); blok1.show(0); blok2.show(0);}
		}

var stronaZaladowana=false;

	function manipulacjaBlokami(a,b,c)
		{
			if(stronaZaladowana==true)
				{
					blok.show(a);
					blok1.show(b);
					blok2.show(c);
				}
		}