$(document).ready(function() {
	$(".download_now").tooltip({ effect: 'slide'});
	$(".gallery a[rel^='prettyPhoto']").prettyPhoto({theme:'facebook'});

	//$("#highlights").scrollable({
		// initialize scrollable together with the autoscroll plugin
		//var root = $("#scroller").scrollable({circular: true}).autoscroll({ autoplay: true });

		// provide scrollable API for the action buttons
		//window.api = root.data("scrollable");
	//	$("#chained").scrollable({circular: true, mousewheel: true}).navigator().autoscroll({
	//		interval: 3000
	//	});
	//});

	$("#rform").validate({
		rules: {
			'form[passwordr]': {
				equalTo: "#password"
			}
		},
		messages: {
			'form[email]': {
				required: "Proszę podać email",
				email: "Proszę podać prawidłowy email"
			},
			'form[password]': "Proszę podać hasło",
			'form[passwordr]': {
				required: "Proszę ponownie podać hasło",
				equalTo: "Proszę podać takie samo hasło jak powyżej"
			},
			'form[fullname]': "Proszę podać imię i nazwisko / nick",
			'form[content]': "Proszę napisać deklarację"
		}
	});


	$(window).load(
	function() {
		//center_highlights();
	});

	function center_highlights(){
		$('#highlights li div img').each(
		function( index ){
			$w = $(this).height();
			$margin = (234 - $w) / 2;
			$(this).attr('style','margin-top: '+$margin+'px');
		});
	}

	try {
		var pageTracker = _gat._getTracker("UA-5664221-22");
		pageTracker._trackPageview();
	} catch(err) {}


});
