﻿function LImage(path) {
    var options = "toolbar=no,scrollbars=yes,resizable=yes"
    msgWindow = window.open(path, "", options);
}

//var IE = document.all ? true : false

//if (!IE) document.captureEvents(Event.MOUSEMOVE)

//document.onmousemove = getMouseXY;

//var tempX = 0
//var tempY = 0


function getMouseXY(e) {
    if (parseInt(navigator.appVersion) > 3) {
        if (navigator.appName == "Netscape") {
            winW = window.innerWidth;
            winH = window.innerHeight;
        }
        if (navigator.appName.indexOf("Microsoft") != -1) {
            winW = document.body.offsetWidth;
            winH = document.body.offsetHeight;
        }
    }

    if (IE) { // grab the x-y pos.s if browser is IE
        tempX = event.clientX + document.body.scrollLeft
        tempY = event.clientY + document.body.scrollTop
    } else {  // grab the x-y pos.s if browser is NS
        tempX = e.pageX
        tempY = e.pageY
    }
    // catch possible negative values in NS4
    if (tempX < 0) { tempX = 0 }
    if (tempY < 0) { tempY = 0 }
    // show the position values in the form named Show
    // in the text fields named MouseX and MouseY
 //   tempX = tempX - (winW / 2);
   // document.getElementById("posx").value = tempX;
    return true
}
function zmenma() {
    document.getElementById('gm').style.display = '';
    document.getElementById('gm3').style.display = 'none';
    document.getElementById('gm4').style.display = 'none';
    document.getElementById('gm4').innerHTML = '';
}

function spustima() {
    document.getElementById('gm').style.display = 'none';
    setTimeout("zmenma()", 20000)
    document.getElementById('gm3').style.display = '';
}
function nahlasit(id) {
}


function checkover(a, nazov) {
    document.getElementById('hodnot').innerText = nazov
    document.getElementById('hodnot').textContent = nazov
    if (document.getElementById('hodm').value == '') {
        document.getElementById('hod' + a).src = '/images/face' + a + 'c.png';
    }
}

function checkout(a, nazov) {
    document.getElementById('hodnot').innerText = nazov
    document.getElementById('hodnot').textContent = nazov
    if (document.getElementById('hodm').value == '') {
        document.getElementById('hod' + a).src = '/images/face' + a + '.png';
    }
}
function checkouta(a, nazov) {
    document.getElementById('hodnot').innerText = nazov
    document.getElementById('hodnot').textContent = nazov
    if (document.getElementById('hodm').value == '') {
        document.getElementById('hod' + a).src = '/images/face' + a + 'b.png';
    }
}

function uprava(a) {
    if (document.getElementById('hodm').value == '') {
        document.getElementById('hodm').value = a;
        document.getElementById('hod' + a).src = '/images/face' + a + 'c.png';
    }
    document.getElementById('hod1').onclick = '';
    document.getElementById('hod2').onclick = '';
    document.getElementById('hod3').onclick = '';
    document.getElementById('hod4').onclick = '';
    document.getElementById('hod5').onclick = '';

}
