
var JSFSplashWin = null;
// static :)
function ShowImage(url, width, height, borderless) {
	ScrWidth = 640; ScrHeight = 480;
	if (window.screen) {ScrWidth = window.screen.width; ScrHeight = window.screen.height}
//	PosX = Math.round((ScrWidth - width)/2);
//	PosY = Math.round((ScrHeight - height)/2);

	PosX = 50;
	PosY = 50;

	if (JSFSplashWin != null && !document.layers) {JSFSplashWin.close();}
	if (borderless && !document.layers) {
		JSFSplashWin = window.open("", "splash", "fullscreen=1,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0");
		JSFSplashWin.resizeTo(width, height);
		JSFSplashWin.moveTo(PosX, PosY);
	}
	else
		JSFSplashWin = window.open("", "splash", "menubar=no,toolbar=no,location=no,directories=no,status=no,scrollbars=no,resizable=no,copyhistory=no,width=" + width + ",height=" + height + ",left=" + PosX + ",top=" + PosY);

	JSFSplashWin.document.open();
	JSFSplashWin.document.clear();
	JSFSplashWin.document.write("<html><head><title>Foto</title><style><!-- body{background: #FFFFFF url(" + url + ") no-repeat;} --></style></head><body scroll='no'><script>function closeMe(e){window.close();} document.onclick = closeMe;</script></body></html>");
	JSFSplashWin.document.close();
	JSFSplashWin.focus();	
}

function JSFSplashShow(url, width, height, borderless) {
	ScrWidth = 640; ScrHeight = 480;
	if (window.screen) {ScrWidth = window.screen.width; ScrHeight = window.screen.height}
//	PosX = Math.round((ScrWidth - width)/2);
//	PosY = Math.round((ScrHeight - height)/2);

	PosX = 50;
	PosY = 50;

	if (JSFSplashWin != null && !document.layers) {JSFSplashWin.close();}
	if (borderless && !document.layers) {
		JSFSplashWin = window.open(url, "splash", "fullscreen=1,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0");
		JSFSplashWin.resizeTo(width, height);
		JSFSplashWin.moveTo(PosX, PosY);
	}
	else
	JSFSplashWin = window.open(url, "splash", "fullscreen=1;menubar=0,toolbar=0,location=0,directories=0,status=0,scrollbars=0,resizable=0,copyhistory=no");
	JSFSplashWin.focus();	
}

