var iDelay=100, iDelayLong=1000, iTimer=-1, nRootID, xIncrement = 160, yIncrement=-4, objElement, d=document, nMenuCount = 6;
var ns6 = document.getElementById && !document.all ? true:false;
var ns4 = document.layers ? true:false;
var ie4 = document.all && !document.getElementById && navigator.userAgent.indexOf("Mac")==-1 ? true:false;
var ie5 = document.all && document.getElementById ? true:false;
var ie4mac = navigator.userAgent.indexOf("Mac")>0 && document.all ? true:false;
function cc( e, c ) {
	if( ie4 || ie5 ) {
		//e = e.children[0]
		if (e.className == "vsmenucell") {
			e.style.backgroundImage = c;
			e.style.backgroundRepeat = "repeat-y";
		}
	}
}
function ccValittu( e, c ) {
	if( ie4 || ie5 ) {
		//e = e.children[0]
		if (e.className == "vsmenucellValittu") {
			e.style.backgroundImage = c;
			e.style.backgroundRepeat = "repeat-y";
		}
	}
}
// Jaanan lisäys alkaa
function cc2( e, c ) {
	if( ie4 || ie5 ) {
		//e = e.children[0]
		if (e.className == "vsmenucell2") {
			e.style.backgroundImage = c;
			e.style.backgroundRepeat = "repeat-y";
		}
	}
}
function OpenPopup(url) {
	var wnd = window.open(url,"DisplayWindow","toolbar=no,directories=no,menubar=no,width=590,height=530,resizable=yes,scrollbars=yes");
	wnd.focus();
}
function OpenPlainPopup(sUrl, sName, iW, iH) {
	var wnd = window.open(sUrl,sName,"toolbar=no,directories=no,menubar=no,width=" + iW + ",height=" + iH + ",resizable=no,scrollbars=no");
	wnd.focus();
}
function OpenPrintWindow(url) {
	var wnd = window.open(url,'print','toolbar=0,menubar=0,scrollbars=1,scrolling="yes",resizable="no",width=645,height=400');
	wnd.focus();
}

