Ignore:
Timestamp:
May 28, 2014, 11:14:27 PM (10 years ago)
Author:
Miklfe
Message:

nouveau carousel: mousewheel; scrollable pour les écrans tactiles
nouvelle lightbox: Fancybox

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/Slim/template/index.tpl

    r28392 r28556  
    33{/if}
    44
    5 {combine_script id='mousewheel' load='header' require='jquery' path='themes/Slim/js/mousewhell.js'}
    65
    76<div id="content" class="content{if isset($MENUBAR)} contentWithMenu{/if}">
     
    98{if ($Slim.style_slim)==1}
    109        {if !empty($THUMBNAILS)}
    11         <div id="home">
    12         <a href="{$U_HOME}"><img src="themes/Slim/images/home.png" height="32px" width="32px"></a>
    13         </div>
    14         <div class="titrePage">
    1510        <div id="infoBlock">
     11        <div class="titrePage slim">
     12                <a href="{$U_HOME}">
     13                <div id="home"></div>
     14                </a>
    1615        {if !empty($PLUGIN_INDEX_ACTIONS)}{$PLUGIN_INDEX_ACTIONS}{/if}
    1716        <h2>
     
    1918        </h2>
    2019        {/if}
    21 
     20        </div>
     21        </div>
    2222{else}
    2323
     
    165165{if !empty($THUMBNAILS)}
    166166                {$THUMBNAILS}
    167 {footer_script}{literal}
    168         $('.jcarousel')
    169             .jcarousel({
    170                  wrap: 'circular',
    171             })         
    172                         .jcarouselAutoscroll({
    173                         autostart: false
    174                         });     
    175                        
    176         $('.jcarousel-control-prev')
    177             .on('jcarouselcontrol:active', function() {
    178                 $(this).removeClass('inactive');
    179             })
    180             .on('jcarouselcontrol:inactive', function() {
    181                 $(this).addClass('inactive');
    182             })
    183             .jcarouselControl({
    184                 target: '-=1'
    185             });
    186167
    187         $('.jcarousel-control-next')
    188             .on('jcarouselcontrol:active', function() {
    189                 $(this).removeClass('inactive');
    190             })
    191             .on('jcarouselcontrol:inactive', function() {
    192                 $(this).addClass('inactive');
    193             })
    194             .jcarouselControl({
    195                 target: '+=1'
    196             });
    197                        
    198     $('.jcarousel').mousewheel(function(event, delta) {
    199         if (delta > 0)
    200             {$('.jcarousel').jcarousel('scroll', '-=1')}
    201         else if (delta < 0)
    202             {$('.jcarousel').jcarousel('scroll', '+=1')}
    203         });
    204 
    205 //};   
    206                
    207 {/literal}{/footer_script}
    208168
    209169{/if}
     
    212172        {if !empty($CATEGORIES)}
    213173                {$CATEGORIES}
    214                 {footer_script}{literal}
    215         $('.jcarousel')
    216             .jcarousel({
    217                  wrap: 'circular'
    218             })         
    219                         .jcarouselAutoscroll({
    220                         interval: 3000,
    221                         target: '+=1',
    222                         autostart: true
    223                         });     
    224                        
    225         $('.jcarousel-control-prev')
    226             .on('jcarouselcontrol:active', function() {
    227                 $(this).removeClass('inactive');
    228             })
    229             .on('jcarouselcontrol:inactive', function() {
    230                 $(this).addClass('inactive');
    231             })
    232             .jcarouselControl({
    233                 target: '-=1'
    234             });
    235174
    236         $('.jcarousel-control-next')
    237             .on('jcarouselcontrol:active', function() {
    238                 $(this).removeClass('inactive');
    239             })
    240             .on('jcarouselcontrol:inactive', function() {
    241                 $(this).addClass('inactive');
    242             })
    243             .jcarouselControl({
    244                 target: '+=1'
    245             });
    246                
    247                 $('.jcarousel')
    248                         .on('mouseenter', function(){
    249                                 $(this).jcarouselAutoscroll('stop')
    250                         })
    251                         .on('mouseleave', function(){
    252                                 $(this).jcarouselAutoscroll('start')
    253                         });
    254                
    255                 $('.jcarousel').mousewheel(function(event, delta) {
    256         if (delta > 0)
    257             {$('.jcarousel').jcarousel('scroll', '-=1')}
    258         else if (delta < 0)
    259             {$('.jcarousel').jcarousel('scroll', '+=1')}
    260         });
    261 
    262 {/literal}{/footer_script}
    263175
    264176        {/if}
Note: See TracChangeset for help on using the changeset viewer.