1_5grid.ready(function() { 2 3 // Desktop-only 4 if (_5grid.isDesktop) 5 { 6 // Vertically center 7 var wh = $(window).height(), w = $('#wrapper'); 8 9 if (_5grid.is1200px && wh > 800) 10 w.css('top', '50%').css('margin-top', '-345px'); 11 else if (_5grid.is1000px && wh > 700) 12 w.css('top', '50%').css('margin-top', '-310px'); 13 14 w.show(); 15 16 // Form key fix 17 $('form').keydown(function(e) { 18 19 switch (e.keyCode) 20 { 21 case 35: // end 22 case 36: // home 23 case 37: // left 24 case 38: // up 25 case 39: // right 26 case 40: // down 27 case 9: // tab 28 e.stopPropagation(); 29 break; 30 31 default: 32 break; 33 } 34 35 }); 36 37 // Slider 38 $('#main').slidertron({ 39 viewerSelector: '.viewer', 40 reelSelector: '.viewer .reel', 41 slidesSelector: '.viewer .reel .slide', 42 navNextSelector: '.next', 43 navPreviousSelector: '.previous', 44 viewerOffset: (_5grid.is1200px ? 102 : 92), 45 jumpLinksSelector: '.jumplink', 46 hashJump: true, 47 speed: 1000, 48 fadeInSpeed: 1000, 49 arrowsToNav: true, 50 onSlideSwitch: function(slide) { 51 $('#main .inner').scrollTop(0); 52 var x = $('body').scrollTop(); 53 slide.find('.inner').focus(); 54 $('body').scrollTop(x); 55 } 56 }); 57 58 $('#main .viewer .reel').accelerate_5grid(); 59 60 // Scrollbars 61 $('article').each(function() { 62 var t = $(this), ti = t.find('.inner'); 63 ti.niceScroll({ 64 body: t, 65 zindex: 2 66 }); 67 }); 68 69 // Tab key fix 70 $(document).keydown(function(e) { if (e.keyCode == 9) e.preventDefault(); }); 71 } 72 73 // Gallery 74 $('.gallery').poptrox( 75 _5grid.isMobile ? 76 { 77 usePopupCaption: false, 78 usePopupCloser: false, 79 useBodyOverflow: false, 80 windowMargin: 0, 81 popupPadding: 5, 82 overlayOpacity: 0.9, 83 fadeSpeed: 0, 84 popupWidth: 0, 85 popupHeight: 0 86 } 87 : 88 { 89 usePopupCaption: true, 90 usePopupCloser: true 91 } 92 ); 93 94}, true);
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.