[8534] | 1 | <div class="navButtons"> |
---|
| 2 | {if $DISPLAY_NAV_BUTTONS or isset($slideshow)} |
---|
| 3 | |
---|
| 4 | {if isset($last)} |
---|
| 5 | <a id="icon_last" class="navButton" href="{$last.U_IMG}" |
---|
| 6 | title="<span class='navDesc'><span class='navAction'>{'Last'|@translate}</span>{if $DISPLAY_NAV_THUMB}<br><img src='{$last.THUMB_SRC}' class='thumbLink thumbNav' id='linkPrev' alt=''>{/if}<br><span class='navTitle'>{$last.TITLE}</span></span>" |
---|
| 7 | rel="last"></a> |
---|
| 8 | {else} |
---|
| 9 | <a id="icon_last_unactive" class="navButton"></a> |
---|
| 10 | {/if} |
---|
| 11 | |
---|
| 12 | {if isset($next)} |
---|
| 13 | <a id="icon_right" class="navButton" href="{$next.U_IMG}" |
---|
| 14 | title="<span class='navDesc'><span class='navAction'>{'Next'|@translate}</span>{if $DISPLAY_NAV_THUMB}<br><img src='{$next.THUMB_SRC}' class='thumbLink thumbNav' id='linkPrev' alt=''>{/if}<br><span class='navTitle'>{$next.TITLE}</span></span>" |
---|
| 15 | rel="next"></a> |
---|
| 16 | {else} |
---|
| 17 | <a id="icon_right_unactive" class="navButton"></a> |
---|
| 18 | {/if} |
---|
| 19 | |
---|
| 20 | {if isset($slideshow.U_START_PLAY)} |
---|
| 21 | <a id="icon_play" class="navButton" href="{$slideshow.U_START_PLAY}" title="{'Play of slideshow'|@translate}"><!-- <img src="{$ROOT_URL}{$themeconf.icon_dir}/play.png" class="button" alt="{'Play of slideshow'|@translate}"> --></a> |
---|
| 22 | {/if} |
---|
| 23 | |
---|
| 24 | {if isset($slideshow.U_STOP_PLAY)} |
---|
| 25 | <a id="icon_pause" class="navButton" href="{$slideshow.U_STOP_PLAY}" title="{'Pause of slideshow'|@translate}"><!-- <img src="{$ROOT_URL}{$themeconf.icon_dir}/pause.png" class="button" alt="{'Pause of slideshow'|@translate}"> --></a> |
---|
| 26 | {/if} |
---|
| 27 | |
---|
| 28 | {if isset($U_UP) and !isset($slideshow)} |
---|
| 29 | <a id="icon_up" class="navButton" href="{$U_UP}" title="{'Thumbnails'|@translate}" rel="up"><!-- <img src="{$ROOT_URL}{$themeconf.icon_dir}/up.png" class="button" alt="{'Thumbnails'|@translate}"> --></a> |
---|
| 30 | {/if} |
---|
| 31 | |
---|
| 32 | {if isset($previous)} |
---|
| 33 | <a id="icon_left" class="navButton" href="{$previous.U_IMG}" |
---|
| 34 | title="<span class='navDesc'><span class='navAction'>{'Previous'|@translate}</span>{if $DISPLAY_NAV_THUMB}<br><img src='{$previous.THUMB_SRC}' class='thumbLink' id='linkPrev' alt=''>{/if}<br><span class='navTitle'>{$previous.TITLE}</span></span>" |
---|
| 35 | rel="prev"></a> |
---|
| 36 | {else} |
---|
| 37 | <a id="icon_left_unactive" class="navButton"></a> |
---|
| 38 | {/if} |
---|
| 39 | |
---|
| 40 | {if isset($first)} |
---|
| 41 | <a id="icon_first" class="navButton" href="{$first.U_IMG}" |
---|
| 42 | title="<span class='navDesc'><span class='navAction'>{'First'|@translate}</span>{if $DISPLAY_NAV_THUMB}<br><img src='{$first.THUMB_SRC}' class='thumbLink thumbNav' id='linkPrev' alt=''>{/if}<br><span class='navTitle'>{$first.TITLE}</span></span>" |
---|
| 43 | rel="first"></a> |
---|
| 44 | {else} |
---|
| 45 | <a id="icon_first_unactive" class="navButton"></a> |
---|
| 46 | {/if} |
---|
| 47 | |
---|
| 48 | |
---|
| 49 | {if isset($slideshow.U_START_REPEAT)} |
---|
| 50 | <a id="icon_start_repeat" class="navButton" href="{$slideshow.U_START_REPEAT}" title="{'Repeat the slideshow'|@translate}"></a> |
---|
| 51 | {/if} |
---|
| 52 | |
---|
| 53 | {if isset($slideshow.U_STOP_REPEAT)} |
---|
| 54 | <a id="icon_stop_repeat" class="navButton" href="{$slideshow.U_STOP_REPEAT}" title="{'Not repeat the slideshow'|@translate}"></a> |
---|
| 55 | {/if} |
---|
| 56 | |
---|
| 57 | {if isset($slideshow)} |
---|
| 58 | {if isset($slideshow.U_DEC_PERIOD)} |
---|
| 59 | <a id="icon_dec_period" class="navButton" href="{$slideshow.U_DEC_PERIOD}" title="{'Accelerate diaporama speed'|@translate}"></a> |
---|
| 60 | {else} |
---|
| 61 | <a id="icon_dec_period_unactive" class="navButton" ></a> |
---|
| 62 | {/if} |
---|
| 63 | |
---|
| 64 | {if isset($slideshow.U_INC_PERIOD)} |
---|
| 65 | <a id="icon_inc_period" class="navButton" href="{$slideshow.U_INC_PERIOD}" title="{'Reduce diaporama speed'|@translate}"></a> |
---|
| 66 | {else} |
---|
| 67 | <a id="icon_inc_period_unactive" class="navButton"></a> |
---|
| 68 | {/if} |
---|
| 69 | {/if} |
---|
| 70 | {/if} |
---|
| 71 | </div> |
---|
| 72 | |
---|
| 73 | <script type="text/javascript">// <![CDATA[ |
---|
| 74 | {literal} |
---|
| 75 | function keyboardNavigation(e) |
---|
| 76 | { |
---|
| 77 | if(!e) e=window.event; |
---|
| 78 | if (e.altKey) return true; |
---|
| 79 | var target = e.target || e.srcElement; |
---|
| 80 | if (target && target.type) return true; //an input editable element |
---|
| 81 | var keyCode=e.keyCode || e.which; |
---|
| 82 | var docElem = document.documentElement; |
---|
| 83 | switch(keyCode) { |
---|
| 84 | {/literal} |
---|
| 85 | {if isset($next)} |
---|
| 86 | case 63235: case 39: if (e.ctrlKey || docElem.scrollLeft==docElem.scrollWidth-docElem.clientWidth ){ldelim}window.location="{$next.U_IMG}".replace( "&", "&" ); return false; } break; |
---|
| 87 | {/if} |
---|
| 88 | {if isset($previous)} |
---|
| 89 | case 63234: case 37: if (e.ctrlKey || docElem.scrollLeft==0){ldelim}window.location="{$previous.U_IMG|@escape:jasvascript}".replace("&","&"); return false; } break; |
---|
| 90 | {/if} |
---|
| 91 | {if isset($first)} |
---|
| 92 | /*Home*/case 36: if (e.ctrlKey){ldelim}window.location="{$first.U_IMG|@escape:jasvascript}".replace("&","&"); return false; } break; |
---|
| 93 | {/if} |
---|
| 94 | {if isset($last)} |
---|
| 95 | /*End*/case 35: if (e.ctrlKey){ldelim}window.location="{$last.U_IMG|@escape:jasvascript}".replace("&","&"); return false; } break; |
---|
| 96 | {/if} |
---|
| 97 | {if isset($U_UP) and !isset($slideshow)} |
---|
| 98 | /*Up*/case 38: if (e.ctrlKey){ldelim}window.location="{$U_UP|@escape:jasvascript}".replace("&","&"); return false; } break; |
---|
| 99 | {/if} |
---|
| 100 | |
---|
| 101 | {if isset($slideshow.U_START_PLAY)} |
---|
| 102 | /*Pause*/case 32: {ldelim}window.location="{$slideshow.U_START_PLAY|@escape:jasvascript}".replace("&","&"); return false; } break; |
---|
| 103 | {/if} |
---|
| 104 | {if isset($slideshow.U_STOP_PLAY)} |
---|
| 105 | /*Play*/case 32: {ldelim}window.location="{$slideshow.U_STOP_PLAY|@escape:jasvascript}".replace("&","&"); return false; } break; |
---|
| 106 | {/if} |
---|
| 107 | } |
---|
| 108 | return true; |
---|
| 109 | } |
---|
| 110 | document.onkeydown=keyboardNavigation; |
---|
| 111 | // ]]></script> |
---|