;function cloudCarouselInit($, el, options, openOnlyActive) {
	var carousel = $(el).CloudCarouselPro(options);

	openOnlyActive = openOnlyActive || false;

	if (openOnlyActive) {
		$(el + " a").click(function(event) {
			if ($(this).hasClass("active"))
				return ;
			
			var data = carousel.data("cloudcarousel"),
				idx = $(this).find('img').data('itemIndex'),
				frontIndex = data.frontIndex,
				diff = idx - frontIndex,
				diff2 = idx - data.itemsCount - frontIndex;
			
			if (Math.abs(diff2) < diff)
				diff = diff2;
	
			data.rotate(-diff);
	
			event.stopImmediatePropagation();
			
			return false;
		});
	}
};