﻿
// Configurando banner principal usando Cycle Plugin
//
// OPTIONS
// -------------------------------------------------------------------------------------------------------------
// fx = Efeito da Animação. Consulte aqui os efeitos disponiveis => http://jquery.malsup.com/cycle/browser.html
// timeout = Tempo de duração do banner.
// Options e Methods: http://jquery.malsup.com/cycle/options.html
// Fonte: http://jquery.malsup.com/cycle/
// Versão Usada: 2.88 (08-JUN-2010)
// =============================================================================================================
    $(function () {

        // Invoco o ID slide-cycle para aplicar o Cycle
        $('#slide-cycle').cycle({
            fx: 'fade',
            pager: '#navBanner',
            timeout: 10000,
            pagerEvent: "mouseover",
            pagerAnchorBuilder: function (idx, slide) {
                // Retorno o valor do rel que nos servira de url para as thumbs
                var $thumb = $(slide).val(function () {
                    var rel = this.rel;
                    return rel;
                })
                return '<a href="#"><img src="' + $thumb.val() + '" width="28" height="28" /></a>';
            }
        });
    })

