Changeset 12534 for extensions


Ignore:
Timestamp:
Oct 31, 2011, 3:39:26 PM (13 years ago)
Author:
plg
Message:

bug fixed: keyboard navigation available on Luciano (thanks to sichr.net for the tip)

bug fixed: compatibility with Google+1 plugin on picture.php

Location:
extensions/luciano/template
Files:
1 added
3 edited

Legend:

Unmodified
Added
Removed
  • extensions/luciano/template/picture.tpl

    r12531 r12534  
    11{if !empty($PLUGIN_PICTURE_BEFORE)}{$PLUGIN_PICTURE_BEFORE}{/if}
     2
     3{include file='picture_nav_keys.tpl'|@get_extent:'picture_nav_keys'}
     4
    25<div id="imageHeaderBar">
    36    <div class="browsePath">
     
    1316    {if !empty($U_SET_AS_REPRESENTATIVE)}<li><a href="{$U_SET_AS_REPRESENTATIVE}" title="{'set as category representative'|@translate}" id="bn-higlight">{'representative'|@translate}</a></li>{/if}
    1417    {if isset($U_ADMIN)                                 }<li><a href="{$U_ADMIN}" title="{'link_info_image'|@translate}" id="bn-edit">{'edit'|@translate}</a></li>{/if}
    15     {if isset($U_CADDIE)                                }
     18    {if isset($U_CADDIE)                                }{*caddie management BEGIN*}
    1619                      <script type="text/javascript">{literal}function addToCadie(aElement, rootUrl, id){if (aElement.disabled) return;aElement.disabled=true;var y=new PwgWS(rootUrl);y.callService("pwg.caddie.add",{image_id: id},{onFailure:function(num,text){alert(num+" "+text);document.location=aElement.href;},onSuccess:function(result){aElement.disabled=false;}});}{/literal}</script>
    1720                      <li><a href="{$U_CADDIE}" onclick="addToCadie(this, '{$ROOT_URL|@escape:'javascript'}', {$current.id}); return false;" title="{'add to caddie'|@translate}" id="bn-caddie">{'caddie'|@translate}</a></li>
    18     {/if}
     21    {/if}{*caddie management END*}
    1922  </ul>
    2023</div>
  • extensions/luciano/template/picture_nav_buttons.tpl

    r5921 r12534  
    1 {* $Id: picture_nav_buttons.tpl 2700 2008-10-10 13:11:31Z rvelices $ *}
    21<div class="navButtons">
    32
     
    5150
    5251</div>
    53 
    54 <script type="text/javascript">// <![CDATA[
    55 {literal}
    56 function keyboardNavigation(e)
    57 {
    58 if(!e) e=window.event;
    59 if (e.altKey) return true;
    60 var target = e.target || e.srcElement;
    61 if (target && target.type) return true; //an input editable element
    62 var keyCode=e.keyCode || e.which;
    63 var docElem = document.documentElement;
    64 switch(keyCode) {
    65 {/literal}
    66 {if isset($next)}
    67 case 63235: case 39: if (e.ctrlKey || docElem.scrollLeft==docElem.scrollWidth-docElem.clientWidth ){ldelim}window.location="{$next.U_IMG}".replace( "&amp;", "&" ); return false; } break;
    68 {/if}
    69 {if isset($previous)}
    70 case 63234: case 37: if (e.ctrlKey || docElem.scrollLeft==0){ldelim}window.location="{$previous.U_IMG|@escape:jasvascript}".replace("&amp;","&"); return false; } break;
    71 {/if}
    72 {if isset($first)}
    73 /*Home*/case 36: if (e.ctrlKey){ldelim}window.location="{$first.U_IMG|@escape:jasvascript}".replace("&amp;","&"); return false; } break;
    74 {/if}
    75 {if isset($last)}
    76 /*End*/case 35: if (e.ctrlKey){ldelim}window.location="{$last.U_IMG|@escape:jasvascript}".replace("&amp;","&"); return false; } break;
    77 {/if}
    78 {if isset($U_UP) and !isset($slideshow)}
    79 /*Up*/case 38: if (e.ctrlKey){ldelim}window.location="{$U_UP|@escape:jasvascript}".replace("&amp;","&"); return false; } break;
    80 {/if}
    81 
    82 {if isset($slideshow.U_START_PLAY)}
    83 /*Pause*/case 32: {ldelim}window.location="{$slideshow.U_START_PLAY|@escape:jasvascript}".replace("&amp;","&"); return false; } break;
    84 {/if}
    85 {if isset($slideshow.U_STOP_PLAY)}
    86 /*Play*/case 32: {ldelim}window.location="{$slideshow.U_STOP_PLAY|@escape:jasvascript}".replace("&amp;","&"); return false; } break;
    87 {/if}
    88 }
    89 return true;
    90 }
    91 document.onkeydown=keyboardNavigation;
    92 // ]]></script>
  • extensions/luciano/template/slideshow.tpl

    r5934 r12534  
    22        <div class="imageNumber">{$PHOTO}</div>
    33</div>
     4
     5{include file='picture_nav_keys.tpl'|@get_extent:'picture_nav_keys'}
     6
    47<div id="slidshowToolBar">{include file='picture_nav_buttons.tpl'|@get_extent:'picture_nav_buttons'}</div>
    58<div id="imageContainer">
Note: See TracChangeset for help on using the changeset viewer.