<!-- <![CDATA[

/*###############################
# DRAG&DROP                     #
###############################*/
var nn6 = document.getElementById && !document.all;
var x,y,presun_objektX,presun_objektY;
var presun_class   = 'presun';
var presun_objekt  = null;	// aktualni presunovany objekt
var presun_objekt2 = null;	// predchozi presunovany objekt. kvuli nastaveni z-indexu

function presunPohyb(udalost)	//mousemove
{
if (presun_objekt!=null)
	{
	presun_objekt.style.left = presun_objektX + (nn6 ? udalost.clientX - x : event.clientX - x) + "px";
	presun_objekt.style.top  = presun_objektY + (nn6 ? udalost.clientY - y : event.clientY - y) + "px";
	return false;							// zablokuj udalost
	}
return true;
}

function presunSpust(udalost)		//mousedown
{
var objekt      = nn6 ? udalost.target : event.srcElement;			// ziskej objekt, na ktery se kliklo
var spoustec=objekt.className;
var top_element = nn6 ? "HTML" : "BODY";
while (objekt.className!=presun_class && objekt.tagName!=top_element)	// opakuj, dokud se nedostanes na tag HTML/BODY nebo na objekt s class rovnajici se hodnote v presun_class
	{
	objekt = nn6 ? objekt.parentNode : objekt.parentElement;
	}
if (objekt.className==presun_class && spoustec=='presun2')
	{
	presun_objekt  = objekt;
	presun_objekt.style.zIndex = 10;
	presun_objektX = parseInt(presun_objekt.style.left + 0);	// ziskej aktualni souradnice objektu
	presun_objektY = parseInt(presun_objekt.style.top  + 0);
	x = nn6 ? udalost.clientX : event.clientX;				// ziskej aktualni polohu mysi
	y = nn6 ? udalost.clientY : event.clientY;
	return false;							// zablokuj udalost
	}
return true;
}

function presunZastav(udalost)	//mouseup
{
if (presun_objekt2!=null)
	{
	presun_objekt2.style.zIndex = 1;
	}
if (presun_objekt!=null)
	{
	presun_objekt.style.zIndex  = 2;
	}
presun_objekt2 = presun_objekt;
presun_objekt  = null;
return true;
}
document.body.onmousedown = presunSpust;
document.body.onmousemove = presunPohyb;
document.body.onmouseup   = presunZastav;


//]]> --> 
