function formatText(index, panel) {
	  return index + "";
  };

$(function () {

    $('.anythingSlider').anythingSlider({
        easing: "easeInOutExpo",        // Anything other than "linear" or "swing" requires the easing plugin
        autoPlay: true,                 // This turns off the entire FUNCTIONALY, not just if it starts running or not.
        delay: 5000,                    // How long between slide transitions in AutoPlay mode
        startStopped: false,            // If autoPlay is on, this can force it to start stopped
        animationTime: 1000,             // How long the slide transition takes
        hashTags: true,                 // Should links change the hashtag in the URL?
        buildNavigation: true,          // If true, builds and list of anchor links to link to each slide
    		pauseOnHover: true,             // If true, and autoPlay is enabled, the show will pause on hover
    		startText: "Go",                // Start text
	        stopText: "Stop",               // Stop text
	      // navigationFormatter: formatText // Details at the top of the file on this use (advanced use)
        navigationFormatter: function(index, panel){
          return ""; // This would have each tab with the text 'Panel #X' where X = index
        }
    });
    
    $("#slide-jump").click(function(){
        $('.anythingSlider').anythingSlider(6);
    });
    
    
});


// News-Slider
function mycarousel_initCallback(carousel) {
    jQuery('.jcarousel-control a').bind('click', function() {
        carousel.scroll(jQuery.jcarousel.intval(jQuery(this).text()));
        return false;
    });

    jQuery('.jcarousel-scroll select').bind('change', function() {
        carousel.options.scroll = jQuery.jcarousel.intval(this.options[this.selectedIndex].value);
        return false;
    });

    jQuery('#mycarousel-next').bind('click', function() {
        carousel.next();
        return false;
    });
    
    jQuery('#mycarousel-next').hover(function() {
        $(this).find('img').attr('src', '/fileadmin/templates/css/img/button_r_h.png');
    }, function() {
    	$(this).find('img').attr('src', '/fileadmin/templates/css/img/button_r.png');
    });


    jQuery('#mycarousel-prev').bind('click', function() {
        carousel.prev();
        return false;
    });
    
    jQuery('#mycarousel-prev').hover(function() {
        $(this).find('img').attr('src', '/fileadmin/templates/css/img/button_l_h.png');
    }, function() {
    	$(this).find('img').attr('src', '/fileadmin/templates/css/img/button_l.png');
    });    
    
    
};

function yet( IN ){
	alert(IN);
	return false;
};

// Ride the carousel...
jQuery(document).ready(function() {
    jQuery("#mycarousel").jcarousel({
        scroll: 1,
        initCallback: mycarousel_initCallback,
        buttonNextHTML: null,
        buttonPrevHTML: null
    });
});






