Changeset 23718


Ignore:
Timestamp:
Jun 30, 2013, 11:15:06 PM (11 years ago)
Author:
flop25
Message:

bug:2848
added two options for the slideshow

ToDo lang var

Location:
trunk/themes/smartpocket
Files:
7 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/themes/smartpocket/js/smartpocket.js

    r23713 r23718  
    33    var options = {
    44      jQueryMobile: true,
    5       captionAndToolbarAutoHideDelay: 0,
     5      loop: var_loop,
     6      captionAndToolbarAutoHideDelay: var_autohide,
    67      imageScaleMethod: "fitNoUpscale",
    78      getToolbar: function(){
    8 return '<div class="ps-toolbar-close"><div class="ps-toolbar-content"></div></div><div class="ps-toolbar-play"><div class="ps-toolbar-content"></div></div><a href="#" id="more_link">More Information</a><div class="ps-toolbar-previous"><div class="ps-toolbar-content"></div></div><div class="ps-toolbar-next"><div class="ps-toolbar-content"></div></div>';},
     9return '<div class="ps-toolbar-close"><div class="ps-toolbar-content"></div></div><div class="ps-toolbar-play"><div class="ps-toolbar-content"></div></div><a href="#" id="more_link">'+var_trad+'</a><div class="ps-toolbar-previous"><div class="ps-toolbar-content"></div></div><div class="ps-toolbar-next"><div class="ps-toolbar-content"></div></div>';},
    910      getImageMetaData:function(el){
    1011        return {
  • trunk/themes/smartpocket/template/thumbnails.tpl

    r23715 r23718  
    55{combine_script id='jquery.ajaxmanager' path='themes/default/js/plugins/jquery.ajaxmanager.js' load='footer'}
    66{combine_script id='thumbnails.loader' path='themes/default/js/thumbnails.loader.js' require='jquery.ajaxmanager' load='footer'}
     7{footer_script}
     8  var var_loop = {if $smartpocket.loop}true{else}false{/if}, var_autohide = {$smartpocket.autohide}, var_trad = "{'More Information'|@translate}";
     9{/footer_script}
    710
    811<ul class="thumbnails">
  • trunk/themes/smartpocket/themeconf.inc.php

    r23716 r23718  
    1212  'mobile' => true,
    1313);
     14
     15// Need upgrade?
     16global $conf;
     17include(PHPWG_THEMES_PATH.'smartpocket/admin/upgrade.inc.php');
     18
    1419
    1520// Redirect if page is not compatible with mobile theme
     
    5762$this->assign('thumbnail_derivative_params', ImageStdParams::get_by_type(IMG_SQUARE));
    5863
    59 //------------------------------------------------------------- mobile version
     64//------------------------------------------------------------- mobile version & theme config
    6065add_event_handler('init', 'mobile_link');
    6166
     
    6368{
    6469  global $template, $conf;
     70  $config = unserialize( $conf['smartpocket'] );
     71  $template->assign( 'smartpocket', $config );
    6572  if ( !empty($conf['mobile_theme']) && (get_device() != 'desktop' || mobile_theme()))
    6673  {
    67     $template->assign('TOGGLE_MOBILE_THEME_URL',
    68         add_url_params(
    69           duplicate_index_url(),
    70           array('mobile' => mobile_theme() ? 'false' : 'true')
    71         )
    72       );
     74    $template->assign(array(
     75                            'TOGGLE_MOBILE_THEME_URL' => add_url_params(duplicate_index_url(),array('mobile' => mobile_theme() ? 'false' : 'true')),
     76      ));
    7377  }
    7478}
Note: See TracChangeset for help on using the changeset viewer.