Changeset 27201 for extensions/Fotorama/template
- Timestamp:
- Feb 5, 2014, 10:43:02 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/Fotorama/template/slideshow.tpl
r27185 r27201 2 2 {combine_script id='fotorama' require='jquery' load='header' path='plugins/Fotorama/fotorama/fotorama.js'} 3 3 4 {literal} 5 <script type="text/javascript"> 6 var image_w = {/literal}{$item_height}{literal} 7 var image_h = {/literal}{$item_height}{literal} 8 </script> 9 {/literal} 10 4 11 <div id="slideshow"> 5 6 7 12 <div id="imageHeaderBar"> 13 <div class="browsePath"> 14 {if isset($U_SLIDESHOW_STOP) } 8 15 [ <a href="{$U_SLIDESHOW_STOP}">{'stop the slideshow'|@translate}</a> ] 9 {/if} 10 <h2 class="showtitle">{$current.TITLE}</h2> 11 </div> 16 {/if} 17 <h2 class="showtitle">{$current.TITLE}</h2> 12 18 </div> 19 </div> 13 20 14 15 16 21 <div id="imageToolBar"> 22 <div class="imageNumber">{$PHOTO}</div> 23 </div> 17 24 18 25 <div id="content"> 19 26 <div id="theImage"> 20 27 <div class="fotorama" data-startindex="{$current_rank}" data-ratio="16/9" data-auto="false" … … 32 39 </div> 33 40 </div> 34 35 < div>41 </div> 42 </div> 36 43 37 <script> 38 $(function () { 39 $('.fotorama') 44 {footer_script require='jquery'}{literal} 45 var fullscreen = false; 46 jQuery().ready(function() { 47 jQuery('.fotorama') 40 48 // Listen to the events 41 49 .on('fotorama:showend ', 42 50 function (e, fotorama, extra) { 51 if (!fullscreen) { 52 history.replaceState(null, null, fotorama.activeFrame['url']+'&slideshow='); 53 jQuery('#slideshow .browsePath a').attr('href', fotorama.activeFrame['url']); 54 jQuery('#slideshow .showtitle').text(fotorama.activeFrame['title']); 55 jQuery('#slideshow .imageNumber').text((fotorama.activeFrame['i'])+'/'+{/literal}{count($items)}{literal}); 56 document.title = fotorama.activeFrame['title'] + ' | {/literal}{$GALLERY_TITLE}{literal}'; 57 } 58 } 59 ) 60 .on('fotorama:fullscreenenter', 61 function (e, fotorama, extra) { 62 fullscreen = true; 63 fotorama.startAutoplay(); 64 } 65 ) 66 .on('fotorama:fullscreenexit', 67 function (e, fotorama, extra) { 68 fullscreen = false; 69 43 70 history.replaceState(null, null, fotorama.activeFrame['url']+'&slideshow='); 44 $('#slideshow .browsePath a').attr('href', fotorama.activeFrame['url']);45 $('#slideshow .showtitle').text(fotorama.activeFrame['title']);46 document.title = fotorama.activeFrame['title'] + ' | {$GALLERY_TITLE}';47 $('#slideshow .imageNumber').text((fotorama.activeFrame['i'])+'/'+{count($items)});71 jQuery('#slideshow .browsePath a').attr('href', fotorama.activeFrame['url']); 72 jQuery('#slideshow .showtitle').text(fotorama.activeFrame['title']); 73 jQuery('#slideshow .imageNumber').text((fotorama.activeFrame['i'])+'/'+{/literal}{count($items)}{literal}); 74 document.title = fotorama.activeFrame['title'] + ' | {/literal}{$GALLERY_TITLE}{literal}'; 48 75 } 49 76 ) … … 51 78 .fotorama(); 52 79 }); 53 </script> 80 {/literal}{/footer_script}
Note: See TracChangeset
for help on using the changeset viewer.