/**
 * Namespace "Kenniskring"
 * @class Main
 * @desc Main 
 */
Base.Kenniskring = function($){
	// Variables & functions defined here are private
	
	function initCarouselQuotes() {
		$initHeight = $('.navboxright ul.carousel-quotes li:first').height();
		$('.navboxright ul.carousel-quotes').css('height',$initHeight);
		$('.navboxright ul.carousel-quotes').cycle({
			dispItems: 1,
			pagination: false,
			speed:  1500,
			timeout: 10000,
			before: function(currSlideElement, nextSlideElement, options, forwardFlag) {  
				$currentht = $(currSlideElement).height();
				if ( $currentht < $(nextSlideElement).height() ) {
					$($(this).parent()).animate({  
					height: $(nextSlideElement).height()  
						}, 500);  
				}
			},
			after: function(currSlideElement, nextSlideElement, options, forwardFlag) {  
				$currentht = $(currSlideElement).height();
				if ( $currentht > $(nextSlideElement).height() ) {
					$($(this).parent()).animate({  
					height: $(nextSlideElement).height()  
						}, 500);  
				}
			}
		});
	}
	
	function initCarouselLogos() {
		$('.navboxright .carousel-logos ul').cycle({
			dispItems: 1,
			pagination: false,
			speed:  1500,
			timeout: 10000
		});
	}
	
	return {
  	// Variables & functions defined here are public
		
		/**
		 * Initialize this Class
		 */
		init: function() {
			initCarouselLogos();
			initCarouselQuotes();
		}
		
	};
}(jQuery);

/* Initialize this class */
Base.register(Base.Kenniskring.init);
