function newImage(arg) {
        if (document.images) {
                rslt = new Image();
                rslt.src = arg;
                return rslt;
        }
}

function changeImages() {
        if (document.images && (preloadFlag == true)) {
                for (var i=0; i<changeImages.arguments.length; i+=2) {
                        document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
                }
        }
}

var preloadFlag = false;
function preloadImages() {
        if (document.images) {
                pic_06_over = newImage("gfx/pic_06-over.gif");
                pic_07_over = newImage("gfx/pic_07-over.gif");
                pic_08_over = newImage("gfx/pic_08-over.gif");
                preloadFlag = true;
        }
}


var JSFSplashWin = null;
function JSFSplashShowImage(url, width, height) {
        borderless=false;
        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);

        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+20, height+20);
                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 center center;} --></style></head><body scroll='no' title='kliknij aby zakmn¹æ to okno'><script>function closeMe(e){window.close();} document.onclick = closeMe;</script></body></html>");
	JSFSplashWin.document.close();
	JSFSplashWin.focus();	
}


