var oldload = function() {};
if(window.navigator.systemLanguage && !window.navigator.language) {
	function h() {
		var l = document.getElementById("navi").firstChild;
		do {
			if (s(l.firstChild)) {
				l.oe = l.onmouseover; l.oa = l.onmouseout;
				l.onmouseover=dups; l.onmouseout=a;
			}
			l = l.nextSibling;
		} while(l);
	}
	
	function s(u) {
		do {
			if(u) u = u.nextSibling;
			if(u && u.nodeName == "UL") return u;
		} while(u);
		return false;
	}
	
	function dups() { var e = s(this.firstChild); if(e) e.style.display = "block"; if(this.oe) this.oe(); }
	function a() { var e = s(this.firstChild); if(e) e.style.display = "none"; if(this.oa) this.oa(); }

	oldload=h;
}

function getSubelems(n) {
	rval = [];
	if( !n || n.nodeType != 1 ) return rval;
	for( i = 0; i < n.childNodes.length; i++ ) {
		var c = n.childNodes[i];
		if(c.nodeType != 1) continue;
		rval.push(c);
	}
	return rval;
}

window.onload = function() {
	var navi = document.getElementById("navi");

	if(navi) {
		var lis = getSubelems(navi);
		for ( li in lis ) {
			var li = lis[li];
			var as = getSubelems(li);

			for ( ai in as ) { (function(an){
				var img = getSubelems(an);
				for( im in img ) {
					if( !isNaN(im) && img[im].nodeName.toLowerCase() == 'img' ) {
						img = img[im];
						break;
					}
				}
				if( img && img.nodeName && img.nodeName.toLowerCase() == 'img'  ) {
					li.onmouseover=function(){if(img.src){img.src=img.src.substr(0,img.src.length-5)+'2.png'}}
					li.onmouseout=function(){if(img.src){img.src=img.src.substr(0,img.src.length-5)+'0.png'}}
				}
			})(as[ai]); }
		}
	}
	oldload();
}
