function zmiana()
{
a.style.left = Math.random()*500;
a.style.top = Math.random()*500;
b.style.left = Math.random()*500;
b.style.top = Math.random()*500;
c.style.left = Math.random()*500;
c.style.top = Math.random()*500;
d.style.left = Math.random()*500;
d.style.top = Math.random()*500;
e.style.left = Math.random()*500;
e.style.top = Math.random()*500;
f.style.left = Math.random()*500;
f.style.top = Math.random()*500;
g.style.left = Math.random()*500;
g.style.top = Math.random()*500;
h.style.left = Math.random()*500;
h.style.top = Math.random()*500;
i.style.left = Math.random()*500;
i.style.top = Math.random()*500;
j.style.left = Math.random()*500;
j.style.top = Math.random()*500;
k.style.left = Math.random()*500;
k.style.top = Math.random()*500;
l.style.left = Math.random()*500;
l.style.top = Math.random()*500;
m.style.left = Math.random()*500;
m.style.top = Math.random()*500;
n.style.left = Math.random()*500;
n.style.top = Math.random()*500;
o.style.left = Math.random()*500;
o.style.top = Math.random()*500;
p.style.left = Math.random()*500;
p.style.top = Math.random()*500;
}


var xx;

function MD(e)
{
xx = event.srcElement.parentElement.style;
X=event.offsetX;
Y=event.offsetY;
}

function MM(e)
{
if (xx)
{
xx.pixelLeft = event.clientX-X + document.body.scrollLeft;
xx.pixelTop = event.clientY-Y + document.body.scrollTop;
return false;
}
}

function MU()
{
xx = null;
}

document.onmousedown = MD;
document.onmousemove = MM;
document.onmouseup = MU;

function obrazek()
{
open("puzzle1/w00.jpg","w00", "width=200, height=150, status=no, toolbar=no, menubar=no, scrollbars=no");
}






