var _num=25
var _bgColor=['','#eeeef0','#eeeef0','#ddddf0','#ff0000']
this.ObjMenu_1=["o firmie ","","20px", _bgColor[1]]
this.ObjMenu_101=["historia kompanii","./menudata_pl/history.html","20px",_bgColor[2]]
this.ObjMenu_102=["wakaty","./menudata_pl/vacancy.html","20px",_bgColor[2]]
this.ObjMenu_2=["wyr&oacute;b","","20px",_bgColor[1]]
this.ObjMenu_201=["drzwi","","20px",_bgColor[2]]
this.ObjMenu_20101=["linia drzewa","./menudata_pl/menu_wood_line.html","20px",_bgColor[3]]
this.ObjMenu_2010101=["standard","./menudata_pl/_standart.html","20px",_bgColor[3]]
this.ObjMenu_2010102=["klasyka-styl ","./menudata_pl/_style.html","20px",_bgColor[3]]
this.ObjMenu_2010103=["harmonia","./menudata_pl/_harmony.html","20px",_bgColor[3]]
this.ObjMenu_2010104=["klasyka","./menudata_pl/_classic.html","20px",_bgColor[3]]
this.ObjMenu_2010105=["horyzont","./menudata_pl/_gorizont.html","20px", _bgColor[3]]
this.ObjMenu_2010106=["gracja","./menudata_pl/_gracia.html","20px", _bgColor[3]]
this.ObjMenu_2010107=["linia","./menudata_pl/_linia.html","20px", _bgColor[3]]
this.ObjMenu_2010108=["sylwetka","./menudata_pl/_syluet.html","20px", _bgColor[3]]
this.ObjMenu_20102=["otwarte drzewo","./menudata_pl/menu_open_wood.html","20px",_bgColor[3]]
this.ObjMenu_2010201=["symetria","./menudata_pl/_symetria.html","20px", _bgColor[3]]
this.ObjMenu_2010202=["akcent","./menudata_pl/_akcent.html","20px", _bgColor[3]]
this.ObjMenu_2010203=["rytm","./menudata_pl/_rytm.html","20px", _bgColor[3]]
this.ObjMenu_2010204=["emocja","./menudata_pl/_emocia.html","20px", _bgColor[3]]
this.ObjMenu_2010205=["sylwetka","./menudata_pl/_syluet.html","20px", _bgColor[3]]
this.ObjMenu_20103=["farbowane HDF ","./menudata_pl/menu_hdf.html","20px",_bgColor[3]]
this.ObjMenu_2010301=["londyn","./menudata_pl/_london.html","20px",_bgColor[3]]
this.ObjMenu_20104=["PWH b&#322;on&#261;","./menudata_pl/menu_pvh.html","20px",_bgColor[3]]
this.ObjMenu_2010401=["elewacja","./menudata_pl/_fasad.html","20px",_bgColor[3]]
this.ObjMenu_20105=["szponocel","./menudata_pl/menu_shponocel.html","20px",_bgColor[3]]
this.ObjMenu_2010501=["idea","./menudata_pl/_idea.html","20px",_bgColor[3]]
this.ObjMenu_2010502=["status","./menudata_pl/_status.html","20px",_bgColor[3]]
this.ObjMenu_20106=["ekocel","./menudata_pl/menu_ekocel.html","20px",_bgColor[3]]
this.ObjMenu_2010601=["elegant","./menudata_pl/_elegant.html","20px",_bgColor[3]]
this.ObjMenu_2010602=["muza","./menudata_pl/_muza.html","20px", _bgColor[3]]
this.ObjMenu_2010603=["trend","./menudata_pl/_trend.html","20px", _bgColor[3]]
this.ObjMenu_20107=["CPL","./menudata_pl/menu_cpl.html","20px",_bgColor[3]]
this.ObjMenu_2010701=["projekt","./menudata_pl/_proekt.html","20px",_bgColor[3]]
this.ObjMenu_202=["drzwi przeciwpo&#380;arowe","./menudata_pl/_ei-30.html","20px",_bgColor[2]]
this.ObjMenu_203=["oc&#347;cie&#380;nice","","20px",_bgColor[2]]
this.ObjMenu_20301=["o&#347;cie&#380;nica regulowana","./menudata_pl/korobka_reg.html","20px",_bgColor[3]]
this.ObjMenu_20302=["o&#347;cie&#380;nica zwyczajna","./menudata_pl/korobka.html","20px",_bgColor[3]]
this.ObjMenu_204=["listwa maskuj&#261;ca","./menudata_pl/lyshtva.html","20px",_bgColor[2]]
this.ObjMenu_205=["na&#347;wietle","./menudata_pl/framuga.html","20px",_bgColor[2]]
this.ObjMenu_206=["aksesoria","./menudata_pl/acces.html","20px",_bgColor[2]]
this.ObjMenu_207=["monta&#380;","","20px",_bgColor[2]]
this.ObjMenu_20701=["monta&#380; o&#347;cie&#380;nicy regulowanej","./menudata_pl/montage_reg.html","20px",_bgColor[3]]
this.ObjMenu_20702=["monta&#380; o&#347;cie&#380;nicy zwyczajnej","./menudata_pl/montage.html","20px",_bgColor[3]]
this.ObjMenu_208=["certyfikaty","./menudata_pl/sert.html","20px",_bgColor[2]]
this.ObjMenu_3=["produkcja","","20px",_bgColor[1]]
this.ObjMenu_301=["fabryka","./under_construction1.html","20px",_bgColor[2]]
this.ObjMenu_302=["technologie","./under_construction1.html","20px",_bgColor[2]]
//this.ObjMenu_4=["partnerom","","20px",_bgColor[1]]
//this.ObjMenu_401=["APS","./menudata_pl/auth.html","20px",_bgColor[2]]
//this.ObjMenu_402=["przedstawicielom","./menudata_pl/auth.html","20px",_bgColor[2]]
//this.ObjMenu_403=["organizacjom budowlanym","./menudata_pl/auth.html","20px",_bgColor[2]]
//this.ObjMenu_404=["architektom i designerom","./menudata_pl/auth.html","20px",_bgColor[2]]
this.ObjMenu_4=["zosta&#263; partnerem","./menudata_pl/partner.html","20px",_bgColor[1]]
this.ObjMenu_5=["kontakty","","20px",_bgColor[1]]
this.ObjMenu_501=["firma \"ÁÐÀÌÀ\" ","./menudata_pl/contacts.html","20px",_bgColor[2]]
this.ObjMenu_502=["ïðåäñòàâíèöòâà òà ä³ëåðè","./menudata_pl/dealers.html","20px",_bgColor[2]]
this.ObjMenu_6=["wsparcie","./menudata_ua/help.html","20px",_bgColor[1]]
this.ObjMenu_7=["biuro","./menudata_ua/mail.html","20px",_bgColor[1]]
this.ObjMenu_8=["nowiny","","20px",_bgColor[1]]
this.ObjMenu_801=["nowiny firmy","./menudata_pl/news.html","20px",_bgColor[2]]
this.ObjMenu_802=["publikacje o drzwiach","./menudata_pl/publications.html","20px",_bgColor[2]]
var _color='#1c4d89'

function AuthPath(LogIn, Passw)
{
	switch(LogIn)
	{
		case 'Svidrak': {if(Passw=='svidrak') return '../QwErTyAsDf/photoes.html'}; break;
	};
	return '../menudata_ua/wrong.html';
}

function checked(Obj, state, _col){
//	alert(_col);
	switch (state){
	case 0:{Obj.style.background=_col; Obj.style.color=_color;}; break;
	case 1:{Obj.style.background='#97baff'; Obj.style.color='white'; Obj.style.cursor='hand'; Obj.style.cursor='pointer';}; break;
	}}

function getHeight(Obj)
{
	var BrowserDetect = {
	init: function () {
		this.browser = this.searchString(this.dataBrowser) || "An unknown browser";
		this.version = this.searchVersion(navigator.userAgent)
			|| this.searchVersion(navigator.appVersion)
			|| "an unknown version";
		this.OS = this.searchString(this.dataOS) || "an unknown OS";
	},
	searchString: function (data) {
		for (var i=0;i<data.length;i++)	{
			var dataString = data[i].string;
			var dataProp = data[i].prop;
			this.versionSearchString = data[i].versionSearch || data[i].identity;
			if (dataString) {
				if (dataString.indexOf(data[i].subString) != -1)
					return data[i].identity;
			}
			else if (dataProp)
				return data[i].identity;
		}
	},
	searchVersion: function (dataString) {
		var index = dataString.indexOf(this.versionSearchString);
		if (index == -1) return;
		return parseFloat(dataString.substring(index+this.versionSearchString.length+1));
	},
	dataBrowser: [
		{ 	string: navigator.userAgent,
			subString: "OmniWeb",
			versionSearch: "OmniWeb/",
			identity: "OmniWeb"
		},
		{
			string: navigator.vendor,
			subString: "Apple",
			identity: "Safari"
		},
		{
			prop: window.opera,
			identity: "Opera"
		},
		{
			string: navigator.vendor,
			subString: "iCab",
			identity: "iCab"
		},
		{
			string: navigator.vendor,
			subString: "KDE",
			identity: "Konqueror"
		},
		{
			string: navigator.userAgent,
			subString: "Firefox",
			identity: "Firefox"
		},
		{
			string: navigator.vendor,
			subString: "Camino",
			identity: "Camino"
		},
		{		// for newer Netscapes (6+)
			string: navigator.userAgent,
			subString: "Netscape",
			identity: "Netscape"
		},
		{
			string: navigator.userAgent,
			subString: "MSIE",
			identity: "Explorer",
			versionSearch: "MSIE"
		},
		{
			string: navigator.userAgent,
			subString: "Gecko",
			identity: "Mozilla",
			versionSearch: "rv"
		},
		{ 		// for older Netscapes (4-)
			string: navigator.userAgent,
			subString: "Mozilla",
			identity: "Netscape",
			versionSearch: "Mozilla"
		}
	],
	dataOS : [
		{
			string: navigator.platform,
			subString: "Win",
			identity: "Windows"
		},
		{
			string: navigator.platform,
			subString: "Mac",
			identity: "Mac"
		},
		{
			string: navigator.platform,
			subString: "Linux",
			identity: "Linux"
		}
	]

};
BrowserDetect.init();

//	alert(BrowserDetect.browser+" --- "+BrowserDetect.version);
//	alert(Obj);
//	alert(Obj.document.body.scrollHeight);
	switch (BrowserDetect.browser){
	case 'Explorer': return Obj.document.body.scrollHeight+'px'; break;
	case 'Opera': return 500+'px'; break;
	case 'Firefox': return Obj.document.height+'px'; break;
	case 'Netscape': return Obj.document.body.scrollHeight+'px'; break;
	}
	return '100px';
//		   Obj.document.body.style.pixelWidth
//	return Obj.document.body.scrollHeight;
//	alert(Data_Frame.filledTable.offsetHeight);
}

function createTable(Obj, level){
	_mf="Data_Frame";
	if (level==0) Obj=menuFrame;
	else{
		Obj=document.getElementById("Sep"+level);
		if(Obj.innerHTML!="") {Obj.innerHTML=""; return}}
	count=level*100+1;
	x=Obj.innerHTML;
	Obj.innerHTML="";
	HTMLStr="<table border=0 cellpadding=0 cellspacing=0 width='100%' bgcolor='#eeeef0'>";
	while (MObj=eval('this.ObjMenu_'+count))
	{
		HTMLStr+="<tr><td class='one' height="+eval("ObjMenu_"+count+"[2]")+" style='padding-left:20px; background:"+eval("ObjMenu_"+count+"[3]")+"'";
		HTMLStr+="onclick='createTable(this, "+count+"); if(ObjMenu_"+count+"[1]) document.getElementById(_mf).src=ObjMenu_"+count+"[1];'";
		HTMLStr+="onmouseover=\"checked(this, 1, '"+eval("ObjMenu_"+count+"[3]")+"')\" ";
		HTMLStr+="onmouseout=\"checked(this,0, '"+eval("ObjMenu_"+count+"[3]")+"') \" id='ObjMenu"+count+"'";
		HTMLStr+=">"+MObj[0]+"</td></tr><tr><td id='Sep"+count+"'  style='padding-left:20px' ></td></tr>";
		count++;
	};
    HTMLStr+="</table>";


	HTMLStr+=x;
	Obj.innerHTML=HTMLStr;
	};

function ShowPattern(color){
	document.getElementById('PattImg').src="../pics/matirials/"+color+"_big.jpg"
	document.getElementById('BigPattern').style.visibility='visible';
	document.getElementById('BigPattern').style.left=20;
};
function HidePattern(color, obj){
	document.getElementById('BigPattern').style.visibility='hidden';
}




