Changeset 27342


Ignore:
Timestamp:
Feb 12, 2014, 3:11:45 PM (6 years ago)
Author:
JanisV
Message:

Disable history update only in native full-screen mode
Hide thumbnails in full-screen mode, hide thumbnails in non full-screen mode

Location:
extensions/Fotorama
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • extensions/Fotorama/admin.php

    r27155 r27342  
    2121  if (isset($_POST['nav']))
    2222    $conf['Fotorama']['nav'] = $_POST['nav'];
     23  if (isset($_POST['fullscreen_nav']))
     24    $conf['Fotorama']['fullscreen_nav'] = $_POST['fullscreen_nav'];
    2325
    2426  conf_update_param('Fotorama', serialize($conf['Fotorama']));
  • extensions/Fotorama/language/en_UK/plugin.lang.php

    r27155 r27342  
    1010$lang['Stops slideshow at any user action with the fotorama'] = 'Stops slideshow at any user action with the fotorama';
    1111$lang['Enables loop'] = 'Enables loop';
     12$lang['Fullscreen navigation style'] = 'Fullscreen navigation style';
    1213
    1314?>
  • extensions/Fotorama/language/ru_RU/plugin.lang.php

    r27200 r27342  
    1010$lang['Stops slideshow at any user action with the fotorama'] = 'Останавливать слайдшоу при любом действии пользователя с Fotorama';
    1111$lang['Enables loop'] = 'Показывать в цикле';
     12$lang['Fullscreen navigation style'] = 'Стиль навигации в полноэкранном режиме';
    1213
    1314?>
  • extensions/Fotorama/maintain.inc.php

    r27155 r27342  
    1616    'loop' => true,
    1717    'nav' => 'false',
     18    'fullscreen_nav' => 'false',
    1819  );
    1920
  • extensions/Fotorama/template/admin.tpl

    r27155 r27342  
    5050  </li>
    5151  <li>
     52    <label for="fullscreen_nav">
     53      <b>{'Fullscreen navigation style'|@translate}</b>
     54    </label>
     55    <select class="categoryDropDown" id="fullscreen_nav" name="fullscreen_nav">
     56      <option value="false"{if $Fotorama.fullscreen_nav == 'false'} selected{/if}>{'false'|@translate}</option>
     57      <option value="dots"{if $Fotorama.fullscreen_nav == 'dots'} selected{/if}>{'dots'|@translate}</option>
     58      <option value="thumbs"{if $Fotorama.fullscreen_nav == 'thumbs'} selected{/if}>{'thumbs'|@translate}</option>
     59    </select>
     60  </li>
     61  <li>
    5262    <input type="checkbox" id="shadows" name="shadows"{if $Fotorama.shadows} checked="checked"{/if}>
    5363    <label for="shadows">
  • extensions/Fotorama/template/slideshow.tpl

    r27201 r27342  
    3434        <a href="{$thumbnail['derivative']->get_url()}"
    3535          data-full="{$thumbnail['derivative_big']->get_url()}" data-url="{$thumbnail['url']}" data-title="{$thumbnail['TITLE']}">
    36           {if $Fotorama['nav'] == 'thumbs'}<img src="{$thumbnail['derivative_thumb']->get_url()}">{/if}
     36          {if $Fotorama['nav'] == 'thumbs' || $Fotorama['fullscreen_nav'] == 'thumbs'}<img src="{$thumbnail['derivative_thumb']->get_url()}">{/if}
    3737        </a>
    3838      {/foreach}
     
    6060        .on('fotorama:fullscreenenter',
    6161            function (e, fotorama, extra) {
    62               fullscreen = true;
     62              fotorama.setOptions({
     63                nav: "{/literal}{$Fotorama['fullscreen_nav']}{literal}"
     64              });
    6365              fotorama.startAutoplay();
     66
     67              if (jQuery('.fotorama').attr('data-allowfullscreen') == 'native')
     68                fullscreen = true;
    6469            }
    6570        )
    6671        .on('fotorama:fullscreenexit',
    6772            function (e, fotorama, extra) {
    68               fullscreen = false;
     73              fotorama.setOptions({
     74                nav: "{/literal}{$Fotorama['nav']}{literal}"
     75              });
    6976
    7077              history.replaceState(null, null, fotorama.activeFrame['url']+'&slideshow=');
     
    7380              jQuery('#slideshow .imageNumber').text((fotorama.activeFrame['i'])+'/'+{/literal}{count($items)}{literal});
    7481              document.title = fotorama.activeFrame['title'] + ' | {/literal}{$GALLERY_TITLE}{literal}';
     82
     83              fullscreen = false;
    7584            }
    7685        )
Note: See TracChangeset for help on using the changeset viewer.