- Timestamp:
- Mar 3, 2012, 7:09:10 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/derivative_std_params.inc.php
r13038 r13472 161 161 { 162 162 self::$watermark = new WatermarkParams(); 163 self::$type_map[IMG_SQUARE] = new DerivativeParams( SizingParams::square(1 00,100) );163 self::$type_map[IMG_SQUARE] = new DerivativeParams( SizingParams::square(120,120) ); 164 164 self::$type_map[IMG_THUMB] = new DerivativeParams( SizingParams::classic(144,144) ); 165 165 self::$type_map[IMG_SMALL] = new DerivativeParams( SizingParams::classic(240,240) ); -
trunk/include/page_tail.php
r13426 r13472 67 67 68 68 //------------------------------------------------------------- mobile version 69 if ( !empty($conf['mobile_theme']) && get_device() != 'desktop')69 if ( !empty($conf['mobile_theme']) && (get_device() != 'desktop' || mobile_theme())) 70 70 { 71 71 $template->assign('TOGGLE_MOBILE_THEME_URL', 72 72 add_url_params( 73 make_index_url(),73 duplicate_index_url(), 74 74 array('mobile' => mobile_theme() ? 'false' : 'true') 75 75 ) -
trunk/themes/smartpocket/template/mainpage_categories.tpl
r13235 r13472 1 {define_derivative name='derivative_params ' width=120 height=120 crop=true}1 {define_derivative name='derivative_params_square' type='square'} 2 2 3 3 <ul data-role="listview" data-inset="true"> … … 5 5 <li> 6 6 <a href="{$cat.URL}"> 7 <img src="{$pwg->derivative_url($derivative_params , $cat.representative.src_image)}">7 <img src="{$pwg->derivative_url($derivative_params_square, $cat.representative.src_image)}"> 8 8 <h3>{$cat.NAME}</h3> 9 9 <p class="Nb_images">{$cat.CAPTION_NB_IMAGES}</p> -
trunk/themes/smartpocket/template/thumbnails.tpl
r13234 r13472 2 2 {combine_script id='klass' path='themes/smartpocket/js/klass.min.js'} 3 3 {combine_script id='photoswipe' path='themes/smartpocket/js/code.photoswipe.jquery.min.js' require='klass,jquery.mobile'} 4 {combine_script id='smartpocket' path='themes/smartpocket/js/smartpocket.js' require='photoswipe'} 5 {combine_script id='jquery.ajaxmanager' path='themes/default/js/plugins/jquery.ajaxmanager.js' load='footer'} 6 {combine_script id='thumbnails.loader' path='themes/default/js/thumbnails.loader.js' require='jquery.ajaxmanager' load='footer'} 4 7 5 {define_derivative name='derivative_params_ thumb' width=120 height=120 crop=true}6 {define_derivative name='derivative_params_ full' type='large'}8 {define_derivative name='derivative_params_square' type='square'} 9 {define_derivative name='derivative_params_large' type='large'} 7 10 8 {footer_script}{literal}9 (function(window, $, PhotoSwipe){10 $(document).ready(function(){11 var options = {12 jQueryMobile: true,13 imageScaleMethod: "fitNoUpscale"14 };15 $(".thumbnails a").photoSwipe(options);16 $(document).bind('orientationchange', set_thumbnails_width);17 set_thumbnails_width();18 });19 }(window, window.jQuery, window.Code.PhotoSwipe));20 21 function set_thumbnails_width() {22 nb_thumbs = Math.max(3, Math.ceil($('.thumbnails').width() / 130));23 width = Math.floor(1000000 / nb_thumbs) / 10000;24 $('.thumbnails li').css('width', width+'%');25 }26 27 {/literal}{/footer_script}28 11 <ul class="thumbnails"> 29 12 {foreach from=$thumbnails item=thumbnail}{strip} 13 {assign var=derivative value=$pwg->derivative($derivative_params_square, $thumbnail.src_image)} 30 14 {if isset($page_selection[$thumbnail.id])} 31 32 <a href="{$pwg->derivative_url($derivative_params_full, $thumbnail.src_image)}" rel="external">33 <img src="{$pwg->derivative_url($derivative_params_thumb, $thumbnail.src_image)}" alt="{$thumbnail.TN_ALT}">15 <li> 16 <a href="{$pwg->derivative_url($derivative_params_large, $thumbnail.src_image)}" rel="external"> 17 <img {if !$derivative->is_cached()}data-{/if}src="{$derivative->get_url()}" alt="{$thumbnail.TN_ALT}"> 34 18 </a> 35 19 </li> 36 20 {else} 37 38 <a href="{$pwg->derivative_url($derivative_params_full, $thumbnail.src_image)}" rel="external"></a>21 <li style="display:none;"> 22 <a href="{$pwg->derivative_url($derivative_params_large, $thumbnail.src_image)}" rel="external"></a> 39 23 </li> 40 24 {/if}
Note: See TracChangeset
for help on using the changeset viewer.