1/** 2 * 3 * @author Tibor Csik <csulok0000> 4 * @copyright (c) 2014, Falatozz.hu 5 */ 6 7if (isMobile) { 8 9 var mobile = {}; 10 11 /** 12 * 13 * Mobile Cart 14 */ 15 mobile.cart = {}; 16 17 mobile.cart.init = function () { 18 $('#cartBox').remove(); 19 20 $('body').append($('#mobileCart')); 21 22 $('#mobileCart').show(); 23 24 var icon = $('#mobileCart .cart-icon'); 25 icon.click(mobile.cart.show); 26 27 var backLink = $('#mobileCart .cart-footer a'); 28 backLink.click(mobile.cart.hide); 29 30 setTimeout(function () { 31 showCartBox(); 32 }, 100); 33 }; 34 35 /** 36 * 37 * @param {event} e 38 * @returns {undefined} 39 */ 40 mobile.cart.show = function (e) { 41 e.preventDefault(); 42 43 var width = $(document).width(); 44 width -= parseInt($('#shoppingcartdiv').css('padding-left')) + parseInt($('#shoppingcartdiv').css('padding-right')); 45 46 $('#mobileCart .cart-content').css({width: width + 'px'}); 47 $('#mobileCart').animate({ 48 left: '0%' 49 }, 500); 50 showCartBox(); 51 }; 52 53 /** 54 * 55 * @param {event} e 56 * @returns {undefined} 57 */ 58 mobile.cart.hide = function (e) { 59 if (typeof e != 'undefined') { 60 e.preventDefault(); 61 } 62 63 $('#mobileCart').animate({ 64 left: '100%' 65 }, 500); 66 67 }; 68 69 mobile.updateIndicator = function () { 70 71 var items = $('#mobileCart').find('.really-this-is-food-name'); 72 $('#mobileCart .indicator').text(items.length); 73 }; 74 75} else { 76 var mobile = false; 77} 78
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.