﻿function changeimage(obj, src)
{        
    obj.src = src;
}

function popup(page, name, width, height, top, left)
{        
    window.open(page,name,'width='+width+',height='+height+',scrollbars=yes,toolbar=no,top='+top+',left='+left);
}

function popvideo(id)
{
    window.open('PopVideo.aspx?videoid='+id,'Video','width=482, height=392 ,scrollbars=no,toolbar=no,top=100,left=100');
}

function getNextVideoSamePlayer() {
    //location.href = document.getElementById('hfLink').value + document.getElementById('hfVideoNextID').value;
    alert('HAAAA');
}

function getNextVideoAnotherPlayer() {
    //location.href = document.getElementById('hfLink').value + document.getElementById('hfVideoAnotherID').value;
    alert('HEEEE');
}

function AlteraEstrelas(nStar, nomeControleStar, nomeControleHF)
{
    var i;
    for (i = 1; i < nStar; i++)
        document.getElementById(nomeControleStar + i).src = 'Img/star.gif';
    
    for (i = nStar + 1; i <= 10; i++)
        document.getElementById(nomeControleStar + i).src = 'Img/star_off.gif';
    
    if (document.getElementById(nomeControleStar + nStar).src.indexOf('Img/star.gif') >= 0)
    {
        document.getElementById(nomeControleStar + nStar).src = 'Img/star_off.gif';
        document.getElementById(nomeControleHF).value = nStar - 1;
    }
    else
    {
        document.getElementById(nomeControleStar + nStar).src = 'Img/star.gif';
        document.getElementById(nomeControleHF).value = nStar;
    }
}

function VerificaResolucao()
{
    var browser = navigator.appName;
    //if (browser == "Microsoft Internet Explorer")
    //{
        //if (screen.width > 800)
        //{
            document.getElementById('ctl00_hfTeste').value = "teste";//screen.width;
        //}
    //}
}