﻿// Simple jQuery Slideshow Script; Released by Jon Raasch (jonraasch.com) under FreeBSD license // modified by R.R.// cała reszta - Radomir Rytych
function rollImages(){$(".d img:first-child").addClass("active");$(".d").each(function (i) {$(this).attr("id","dyn"+i);});for (i=0;i<$(".d").length;i++) setTimeout("eval(setInterval(\"slideSwitch('#dyn"+i+"');\",8000))",i*2500);$(".dyn .back").css({opacity:0.6});};function slideSwitch(txt) {var speed=($.browser.msie && $.browser.version=="6.0")?50:1000;var $active = $(txt+' IMG.active');if ( $active.length == 0 ) $active = $(txt+' IMG:last');var $next =  $active.next().length ? $active.next(): $(txt+' IMG:first');$active.addClass('last-active');$next.css({opacity: 0.0}).addClass('active').animate({opacity: 1.0}, speed, function() {$active.removeClass('active last-active');});};$(document).ready(function(){var $sidebar=$("#lewo");if ($sidebar.length==1){var $window=$(window),$side_offset=$sidebar.offset();var u=location.href;if($sidebar.height()<($window.height()-150)&&u.indexOf('high-def')<=0&&typeof no_roll=='undefined')$window.scroll(function(){if($window.scrollTop()>$side_offset.top){$sidebar.stop().animate({marginTop:$window.scrollTop()-$side_offset.top+30})}else{$sidebar.stop().animate({marginTop:0})}})};rollImages();});
