$(document).ready(function(){
        $("#slides").slides({
                preload: false,
                play: 5000,
                pause: 2500,
                hoverPause: true,
                effect:'fade',
                pagination :false,
                randomize :true,
                generatePagination :false
        });
    
        $('#slider-wrapper').preloadSlide({
                preloadedImages: 100, // default 7
                imageArray:arrayFotografia,
                createImageTags:false, // default false
                basePath:false, // default false
                modelName:'PhotographerImage', // Model name if the image array comes as imageArray[n].modelName.fileNameField
                fileNameField: 'thumb', // File name field if the image array comes as imageArray[n].modelName.fileNameField
                captionField:'caption', // Caption field if the image array comes as imageArray[n].modelName.captionField
                createCaptionTags: true, // Wether caption tags are already in the  array or should the plugin create them instead
                autoSlideshowTime: 5000, // time interval for auto slideshow (milliseconds. Default is false (manual advance)
                nextButtonId:'next', // ids for navigation buttons . Default is 'next' and 'prev'
                prevButtonId:'prev',
                imageContainerClass:'slider_home',
                animateFadeAspect:false, //it will animate the size of the container box to match the dimensions of the new image for a better transition
                hoverPause: true
        });
        $('#about .textBlock').addClass('contracted');
        $('#about h2 a').click(function(event){
                event.preventDefault();
                $('#about .textBlock').stop(true,true).delay(1).toggleClass('contracted','fast');
        })
        
   
              
        var textScanOptions={ 
                initColor:'fc7a01',
                endColor:'fc7a01',
                transColor:'2d0c57',
                direction:'->',
                amplitude:100,
                step:22,
                spanize:1,
                unspanize:-1,
                spanClass:'textSpanized',
                maxGroup:2,
                timeInterval:400
        };
        
        if (!$.browser.msie){
                $('li.textos').each(function(){
                        $(this).textscan(textScanOptions);
                });
                        
                        
        }else{
                $('.nivo-caption, .slideImageCaption').addClass('noOpacity');
                $('li.textos').each(function(){
                        $(this).textscan(textScanOptions);
                });
        }
});


