1 2(function($){ 3 4 $(document).ready(function(){init();}); 5 $(window).load(function(){onWindowLoad();}); 6 $(window).resize(function(){onWindowResize();}); 7 8 var lastWidthOfGrid = 0; 9 10 function init() 11 { 12 resizeGrid(); 13 lastWidthOfGrid = 0; 14 15 if($.fn.colorbox) 16 { 17 $('.sc-sponsor-grid .sc-sponsor-handle').click(function(e) 18 { 19 var sponsorInfo = $(this).closest('.sc-sponsor').find('.sc-sponsor-info').html(); 20 21 $.colorbox({ 22 html:sponsorInfo, 23 maxWidth:'75%' 24 }); 25 }); 26 } 27 else if($.fn.fancybox) 28 { 29 $('.sc-sponsor-grid .sc-sponsor-handle').click(function(e) 30 { 31 var sponsorInfo = $(this).closest('.sc-sponsor').find('.sc-sponsor-info').html(); 32 33 $.fancybox({ 34 content:sponsorInfo, 35 width:'75%' 36 }); 37 }); 38 } 39 else 40 { 41 $('.sc-sponsor-grid .sc-sponsor-handle').hide(); 42 } 43 } 44 45 function onWindowLoad() 46 { 47 resizeGrid(); 48 } 49 50 function onWindowResize() 51 { 52 resizeGrid(); 53 } 54 55 function resizeGrid() 56 { 57 var currentWidthOfGrid = $('.sc-sponsor-grid').width(); 58 59 if(currentWidthOfGrid != lastWidthOfGrid) 60 { 61 var pattern = '.sc-sponsor-grid .sc-sponsor-image a, .sc-sponsor-grid .sc-sponsor-image span'; 62 63 $(pattern).height($(pattern).width() + 'px'); 64 } 65 66 lastWidthOfGrid = $('.sc-sponsor-grid').width(); 67 } 68 69})(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.