var bmute = false;

function showerror()
{
 alert('Please download and install TVU player first then enjoy the TV programs.');
 return true;
}

function play(url1)
{
     var showurl="tvup://ps3.tvunetworks.com:3940/"+url1+".0.0.0";
     tvu.Stop();
     tvu.Play(showurl);
     while(tvu.Mute != bmute){
     	mute();
     }
}

function stop()
{
	tvu.Stop();
}

function killErrors() {
	return true;
}

function refresh()
{
	tvu.Refresh();
}

function vup()
{
	var nVol = tvu.Volume + 15;
	if(nVol >= 100)
		tvu.Volume = 100;
	else
		tvu.Volume = nVol;
}

function vdown()
{
	var nVol = tvu.Volume - 15;
	if(nVol <= 0)
		tvu.Volume = 0;
	else
		tvu.Volume = nVol;
}

function mute()
{
	if(!tvu.Mute){
		tvu.Mute = true;
		bmute = true;
	}
	else
	{
		tvu.Mute = false;
		bmute = false;
	}
};