Changeset 1462043
- Timestamp:
- 07/28/2016 08:49:24 AM (10 years ago)
- Location:
- smart-image-loader/trunk
- Files:
-
- 3 edited
-
options.php (modified) (1 diff)
-
plugin.php (modified) (2 diffs)
-
smart_image_loader.min.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
smart-image-loader/trunk/options.php
r1462034 r1462043 16 16 <tr valign="top"> 17 17 <th scope="row">Lazy load below</th> 18 <td><input type="number" name="sil-lazy-load-at" id="sil-lazy-load-at" value="<?php echo get_option('sil-lazy-load-at', ' 0'); ?>" /><br/>Maximum screen width (in pixels) for lazy loading, assuming small screen devices tend to run on bandwidth critical connections. Set to 0 to disable or very high to force.</td>18 <td><input type="number" name="sil-lazy-load-at" id="sil-lazy-load-at" value="<?php echo get_option('sil-lazy-load-at', '1024'); ?>" /><br/>Maximum screen width (in pixels) for lazy loading, assuming small screen devices tend to run on bandwidth critical connections. Set to 0 to disable or very high to force.</td> 19 19 </tr> 20 20 -
smart-image-loader/trunk/plugin.php
r1462034 r1462043 115 115 refresh_scroll: <?= get_option('sil-refresh-scroll', 'false') ? 'true' : 'false' ?>, 116 116 enhanced_accuracy: <?= get_option('sil-accuracy', 'false') ? 'true' : 'false' ?>, 117 lazy_load_at: <?= get_option('sil-lazy-load-at', ' ') ?>,117 lazy_load_at: <?= get_option('sil-lazy-load-at', '1024') ?>, 118 118 fade: <?= get_option('sil-fade', 'false') ? 'true' : 'false' ?>, 119 119 placeholder: <?= '"' . get_option('sil-placeholder', 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7') . '"' ?>, … … 172 172 add_option( 'sil-refresh-scroll', 'false'); 173 173 add_option( 'sil-accuracy', 'false'); 174 add_option( 'sil-lazy-load-at', ' 0');174 add_option( 'sil-lazy-load-at', '1024'); 175 175 add_option( 'sil-fade', 'false'); 176 176 add_option( 'sil-placeholder', 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7'); -
smart-image-loader/trunk/smart_image_loader.min.js
r1462037 r1462043 18 18 x=Q;}if(S()){u=M().width;H=M().height;a(s);if(W.refresh_resize){a(s);}G();T=X;}if(!t){L.requestAnimationFrame(B);}else{b();}},P=function(){r=D("html, body"); 19 19 o=D("body").find("noscript[data-sil]");s=D(W.selector+"[data-sil]");u=M().width;H=M().height;e=V.location.protocol+"//"+V.location.host+"/";C=v.scrollTop(); 20 j=v.scrollLeft();c=v.height();A=D([]); inertia=false;rubberbanding=false;t=s.length>0?false:true;a(s);G(true);B();n=true;};rf_poly();h();})(jQuery);function rf_poly(){var b=0;21 var c=["webkit","moz"];for(var a=0;a<c.length&&!window.requestAnimationFrame;++a){window.requestAnimationFrame=window[c[a]+"RequestAnimationFrame"];window.cancelAnimationFrame=window[c[a]+"CancelAnimationFrame"]||window[c[a]+"CancelRequestAnimationFrame"];20 j=v.scrollLeft();c=v.height();A=D([]);t=s.length>0?false:true;a(s);G(true);B();n=true;};rf_poly();h();})(jQuery);function rf_poly(){var b=0;var c=["webkit","moz"]; 21 for(var a=0;a<c.length&&!window.requestAnimationFrame;++a){window.requestAnimationFrame=window[c[a]+"RequestAnimationFrame"];window.cancelAnimationFrame=window[c[a]+"CancelAnimationFrame"]||window[c[a]+"CancelRequestAnimationFrame"]; 22 22 }if(!window.requestAnimationFrame){window.requestAnimationFrame=function(h,e){var d=new Date().getTime();var f=Math.max(0,16-(d-b));var g=window.setTimeout(function(){h(d+f); 23 23 },f);b=d+f;return g;};}if(!window.cancelAnimationFrame){window.cancelAnimationFrame=function(d){clearTimeout(d);};}}
Note: See TracChangeset
for help on using the changeset viewer.