
function ToggleAccountRowsVisibility(check) {
	if (check.checked) {
		document.getElementById('loginRow').style.display = '';
		document.getElementById('passwdRow').style.display = '';
		document.getElementById('passwd2Row').style.display = '';
	}
	else {
		document.getElementById('loginRow').style.display = 'none';
		document.getElementById('passwdRow').style.display = 'none';
		document.getElementById('passwd2Row').style.display = 'none';
	}
}

function ToggleCommentFormVisibility(zwin, rozwin, zawszeRozwijaj) {
	rozwiniete = document.getElementById('formularzContainer').style.display;
	if (rozwiniete == 'block' && zawszeRozwijaj == 0) {
		document.getElementById('formularzContainer').style.display = 'none';
		document.getElementById('formularzZwinRozwin').innerHTML = rozwin;
	}
	else {
		document.getElementById('formularzContainer').style.display = 'block';
		document.getElementById('formularzZwinRozwin').innerHTML = zwin;
	}
}

function ToggleCompanyRowsVisibility(pokaz) {
	if (pokaz) {
		document.getElementById('firmaRow').style.display = '';
		document.getElementById('nipRow').style.display = '';
	}
	else {
		document.getElementById('firmaRow').style.display = 'none';
		document.getElementById('nipRow').style.display = 'none';
	}
}

$(function(){
	var szerokosc;
	$('#jq-bgpos li').each(function(){
		szerokosc = $(this).width();
		$(this).find("img").attr("width",szerokosc);
	});
	$('#jq-bgpos a').not(".wcisniety")
		.mouseover(function(){
			$(this).children(".hover").stop().animate({top: "-1px"}, 1000, 'easeOutElastic'
			)
		})
		.mouseout(function(){
			$(this).children(".hover").stop().animate({top:"-100px"}, {
			duration:1000, 
			complete:function(){
				$(this).children(".hover").css({top: "-100px"})
			}})
		})
});

