function mover(obj, idx) { 
	if (idx == currentItem) { obj.className = 'playinghi'; }
	else  { obj.className = 'playlisthi'; }
}


function mout(obj, idx) {
	linkFlag = false;
	if (idx == currentItem) { obj.className = 'playinglo'; }
	else  { obj.className = 'playlistlo'; } 
}


function setItemStyle(idx) {
	var count = getLength();





	for(var i=0; i<count; i++) { 
		var tmp = document.getElementById("itm" + i);
		if (tmp) { 
			if(i == idx) {

if(currentState == 'PLAYING') { 
tmp.className = 'playinglo'; 

} //'playinghi';

				else { tmp.className = 'playlisthi'; } //'playinglo';
			} else { tmp.className = 'playlistlo'; }
		}
	}
	var tmp = document.getElementById("plstwrapper");
	tmp.scrollTop = idx * 80;
}






function getLength() { currentLength = player.getPlaylist().length; return(currentLength); };


function printPlaylistData() {
	var plst = null;
	plst = player.getPlaylist();
	if (plst) {
		var txt='<table cellPadding="2" width="410">'; 
		for(var i in plst) { 
 			txt+='<tr><td><table width="410" id="itm' + i + '" onclick="if(! linkFlag) player.sendEvent(\'ITEM\',' + i + ');" ';
 			txt+='class="playlistlo" onmouseover="mover(this, ' + i + ')" onmouseout="mout(this, ' + i + ')">';
			txt+='<tr><td><img src="' + plst[i].image + '" width="90"  height="68" title="Click to Play"></td>';
			txt+='<td width="276" valign=middle><p>';
			txt+=plst[i].title + '<br>';
			txt+='<b>' + plst[i].author + '</b><br>';
			txt+='<a href="' + plst[i].link + '" target="_blank" title="' + plst[i].link + '" onclick="linkFlag=true"> more info</a><br>';
			//txt+=plst[i].description;
			txt+='</p></td></tr></table></td></tr>';
		}
		txt+='</table>'; //alert(txt);

		var tmp = document.getElementById("plstDat");
		if (tmp) { tmp.innerHTML = txt; }
	} else {
		setTimeout("printPlaylistData()",100);
	}	
}




AW=screen.availWidth;
AH=screen.availHeight;

var largh ="";
var altez ="";

		if((AW<1048) && (AH<800)){
                largh=550;
                altez=309;
		}else{
                largh=800;
                altez=450;
		}

//alert(''+largh+' '+altez);



	