function Fn_showshadow(){
	if (igkutil.$("shadow_layer")) return false;
	var alpha = 50; 
	var body = document.getElementsByTagName("body")[0];
	var shadow = document.createElement("div");
	shadow.id = "shadow_layer";
	with (shadow.style){		
		position = "absolute";
		zIndex = "80";
		width = body.scrollWidth + "px";
		height = body.scrollHeight + "px";
		top = "0";
		left = "0";
		backgroundColor = "#000000";
		filter = "alpha(opacity='"+alpha+"')";
		opacity = (alpha/100);
	}
	body.appendChild(shadow);
}

igkutil.AddEvent (window, "load", function() {
	igkutil.AddEvent (window, "resize", function(){
		if (!igkutil.$("shadow_layer")) return false;
		var body = document.documentElement;
		var width = (body.offsetWidth < 1000) ? 1020 + "px" : body.scrollWidth + "px";
		var height = body.scrollHeight + "px";		
		igkutil.$("shadow_layer").style.width = width;
		igkutil.$("shadow_layer").style.height = height;
	});	
});

function Fn_closeshadow(){
	var body = document.getElementsByTagName("body")[0];
	body.removeChild(igkutil.$("shadow_layer")); 
}

function show(p){
	Fn_showshadow();
	document.getElementById(p).style.zIndex = "100";
	document.getElementById(p).style.display = "block";
	var alpha = 0;

	if ((navigator.appName.indexOf('Microsoft')+1)) {
		document.getElementById(p).style.filter = "alpha(opacity='"+alpha+"')";
	}else{
		document.getElementById(p).style.opacity = (alpha/100);
	}

	var action = function() {
		if (timer) clearTimeout(timer);
		if (alpha < 100){
			var plus = Math.ceil(Math.abs( (alpha - 100) / 2 ));
			alpha = (plus < 100) ? alpha + plus : alpha - plus;
		
			if ((navigator.appName.indexOf('Microsoft')+1)) {
				document.getElementById(p).style.filter = "alpha(opacity='"+alpha+"')";
			}else{
				document.getElementById(p).style.opacity = (alpha/100);
			}
		}else{
			return;
		}
		var timer = setTimeout(action,10);
	}
	action();
}

function show1(p){
	document.getElementById(p).style.display = "block";
	var alpha = 0;

	show_tracking(p);
}

function hide(p){
  Fn_closeshadow();
  document.getElementById(p).style.display = "none";

}
