
// ==================================================
// MOUSEOVER FUNCTION (CAMBIO TARGET)
// ==================================================
function tocItem (imgName) {
    this.name = imgName
    this.off		= new Image();
    this.off.src	= "/images/btn_empty.jpg";
    this.sel		= new Image();
    this.sel.src	= "/images/btn_" + imgName + ".jpg";
}

function createTocItem (imgName) {
    tocItem [imgName] = new tocItem (imgName)
}

function tocMouseOver(imgName) {
    document ['tMenu'].src =  tocItem[imgName].sel.src;
}

function tocMouseOut(imgName) {
	document ['tMenu'].src = tocItem[imgName].off.src;
}

createTocItem("empty");
createTocItem("genitori");
createTocItem("ragazzi");
createTocItem("adulti");

// ==================================================
// OPEN SECONDARY WINDOW : PAROLE
// ==================================================
function openWindow(mUrl, mTarget, mWidth, mHeight) {
	msgWin = window.open(mUrl, mTarget,'scrollbars=yes,resizable=no,width='+mWidth+',height='+mHeight+',status=no,location=no,toolbar=no', marginwidth=0, marginheight=0);
	msgWin.focus();
}

// ==================================================
// OPEN SECONDARY WINDOW : MMS
// ==================================================
function openWindowMms(mTarget, mWidth, mHeight) {
	msgWin = window.open('', mTarget,'scrollbars=no,resizable=no,width='+mWidth+',height='+mHeight+',status=no,location=no,toolbar=no', marginwidth=0, marginheight=0);
	msgWin.focus();
}

// ==================================================
// SHOW DICTIONARY 
// ==================================================
function showDict(id) {
	openWindow("../dizionario/view.asp?ID=" + id, 'dizionario', 450, 250);
}


// ==================================================
// SHOW DICTIONARY 
// ==================================================
function doSomething(e) {

	// posx and posy contain the mouse position relative to the document
	// Do something with this information
}

// ==================================================
// OPEN SECONDARY WINDOW : PAROLE
// ==================================================
function openWin(mTarget, mWidth, mHeight) {
	msgWin = window.open('', mTarget,'scrollbars=yes,resizable=yes,width='+mWidth+',height='+mHeight+',status=no,location=no,toolbar=no', marginwidth=0, marginheight=0);
	msgWin.focus();
}