function popup(url, width, height)
{
    var left = parseInt((screen.width - width) / 2);
    var top = parseInt ((screen.height - height) / 2);

    popupWindow = window.open (url, '', 'toolbar=no,status=no,left=' + left + ',top=' + top + ',width=' + width + ',height=' + height);
}

function closerefresh()
{
    window.close ();

    if (typeof (top.opener.document) == 'object')
        top.opener.location.reload();
}

function edit(artist, title)
{
	popup('http://www.lyricsplugin.com/wmplayer03/edit/?artist=' + encodeURIComponent(artist) + '&title=' + encodeURIComponent(title), 500, 550);
}

function tellafriend()
{
	popup('http://www.lyricsplugin.com/tellafriend/', 500, 400);
}

function configure()
{
	popup('http://www.lyricsplugin.com/wmplayer03/configure/', 600, 600);
}

function translate(artist, title)
{
	popup('http://www.lyricsplugin.com/wmplayer03/translate/?artist=' + encodeURIComponent(artist) + '&title=' + encodeURIComponent(title), 600, 800);
}