var e = '@';
var mt = 'o:';
var ml = 'ma'+'il'+'t'+mt;
function menu(id, idArray, mode) {
	//alert('menu filter start...');
	if (id == null || idArray == null) return;
	status = '-';
	disp = '';
	if (document.getElementById('lm_p' + id).style.display == disp
	    || document.getElementById('lm_p' + id).style.display == '') {
		status = '+';
	}
	if (status == '+') {
		document.getElementById('lm_p' + id).style.display='none';
		document.getElementById('lm_m' + id).style.display=disp;
		for (i = 0; i < idArray.length; i++) {
			document.getElementById('lm_' + idArray[i]).style.display=disp;
		}
		return;
	}
	if (status == '-') {
		document.getElementById('lm_p' + id).style.display=disp;
		document.getElementById('lm_m' + id).style.display='none';
		for (i = 0; i < idArray.length; i++) {
			document.getElementById('lm_' + idArray[i]).style.display='none';
			if (mode ==2) {
				obj = document.getElementById('lm_p' + idArray[i]);
				if (obj != null) obj.style.display=disp;
				obj = document.getElementById('lm_m' + idArray[i]);
				if (obj != null) obj.style.display='none';
			}
		}
		return;
	}
}
function cellclick(url)	
{
	window.location.href=url;
}
function cursor(obj, mode) {
	//verify for netscape/mozilla
	var isNS4 = (navigator.appName=="Netscape")?1:0;
	if (!isNS4) {
		if (mode == 1) obj.style.cursor='hand';
		else obj.style.cursor='default';
	} else {
		if (mode == 1) obj.style.cursor='pointer';
		else obj.style.cursor='default';
	}
}
function nW(link, name, w, h, scroll, resizable, top, left) {
if (w == null) w = 840;
if (h == null) h = 620;
if (scroll == null) scroll = 'yes';
if (resizable == null) resizable = 'yes';
if (top == null) top = 20;
if (left == null) left = 5;
winprops = 'height='+h+',width='+w+',scrollbars='+scroll+',resizable='+resizable+',top='+top+',left='+left;
win = window.open(link, name, winprops);
if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}

function nWfinv(link, name, title, text, w, h, scroll, resizable, top, left) {
if (w == null) w = 840;
if (h == null) h = 650;
if (scroll == null) scroll = 'yes';
if (resizable == null) resizable = 'yes';
if (top == null) top = 20;
if (left == null) left = 5;
if (title == null) title = 'Buh. apskaitos programa Finvalda';
winprops = 'height='+h+',width='+w+',scrollbars='+scroll+',resizable='+resizable+',top='+top+',left='+left;
win = window.open('', name, winprops);

win.document.write('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><title>'+title+'</title>');
win.document.write('<meta http-equiv="Content-Type" content="text/html; charset=utf-8">');
win.document.write('<link rel="stylesheet" type="text/css" href="/styles.css">');
win.document.write('</head>');
win.document.write('<body class="bodyNewWin" >');
win.document.write('<div align="center"><strong>'+title+'</strong></div>');
if (text != null) win.document.write('<p style="text-align:justify">'+text+'</p>');
win.document.write('<p align="center"><img src="'+link+'" alt="" border="0"></p>');
win.document.write('<div align="center"><a href="javascript:window.close();">Uždaryti langą</a></div>');
win.document.write('</body></html>');

if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}
