1/* RETINISE.JS --------------------------------------------------* 2 3 Author: Simon Sturgess 4 @dahliacreative 5 [email protected] 6 http://www.dahliacreative.com 7 8 Thanks to: Pedro Piedade 9 @iampedropiedade 10 http://pedropiedade.com/ 11 12 Documentation: http://www.dahliacreative.com/retinisejs 13 14 Release date: 27/09/2012 15 Version: v.1.0 16 Licensing: © Copyright 2012 DahliaCreative. 17 Free to use under the GPLv2 license. 18 http://www.gnu.org/licenses/gpl-2.0.html 19 20*--------------------------------------------------------------------*/(function(e){e.fn.extend({retinise:function(t){var n={suffix:"@2x",srcattr:"data-src",retattr:"data-ret",altattr:"data-alt"},r=e.extend(n,t),i=window.devicePixelRatio,s=i>1?!0:!1;e(this).each(function(){var t=e(this),n=t.css("display");t.css("display","none");if(t.attr(r.srcattr)){var o=t.attr(r.srcattr),u=t.attr(r.altattr),a=t.attr(r.retattr);if(s===!0){t.attr(r.retattr)?t.attr({src:a,alt:u}):t.attr({src:o.replace(/\.\w+$/,function(e){return r.suffix+e}),alt:u});t.load(function(){var e=t.height()/i,r=t.width()/i;t.attr({height:e,width:r}).css({display:n})})}else t.attr({src:o,alt:u}).css({display:n})}})}})})(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.