showlist = false;
$('#gamelist').hover(function(){
                      
                      },function(){
                              $("#gamelist").slideUp('slow');
							  showlist = false;
                           });
 
function showgamelist()
{
	if(!showlist)
	{
		$("#gamelist").slideDown('slow');
		showlist = true;
	}
	else
	{
		$("#gamelist").slideUp('slow');
		showlist = false;
	}
}

function changeRate(ele)
	{
		$.get("/ajax/changeCurrencyType/"+ele, null, function (data, textStatus){
				if ( textStatus == "success")
				{
					window.location.href = "/";
				}										
			});
	}
	
function quickbuy()
{
	if($("#selectGame").val() != 0 && $("#selectBlock").val() != 0)
	{
		window.location.href = "/fillorder/fillgoldorder/"+$("#selectServer").val()+"/"+$("#selectBlock").val()+"/"+$("#selectGame").val();
	}

}

function ajaxAddOptions(url, target, id, text){  
     target.empty();  
     $.getJSON(url, function(json){  
         $(json).each(function(i){  
             var x = json[i];  
             target.append("<option value='" + eval("x." + id) + "'>" + eval("x." + text) + "</option>" );  
         })  
     });  
}

function PostCur(nCurID)
{	
	if ( $('#radCurency')[0].value != nCurID)
		$('#radCurency')[0].value = nCurID;	
	else
		return;
		
	$('#paymentform').submit();	
}
