1var ua_native = window.navigator.userAgent.toLowerCase(); 2var ipad_true_flag = false; 3if(ua_native.indexOf('ipad') > -1 || ua_native.indexOf('macintosh') > -1 && 'ontouchend' in document){ 4 ipad_true_flag = true; 5} 6$(function(){ 7 //menu_back 8 $('#container').append('<div id="mnBack"></div>'); 9 10 11 //ã¬ã¹ãã³ã·ã 12 var respons_flg = true; 13 14 var size_sp = 480; 15 var size_tb = 768; 16 var size_pc = 1024; 17 18 //user_agent 19 var ua_val = $.ua_val(); 20 var device_mode = ua_val.mode; 21 var uaMcn = ua_val.os; 22 var uaVer = ua_val.ver; 23 24 if(ipad_true_flag) { 25 device_mode = 'Tablet'; 26 uaMcn = 'iPad'; 27 } 28 29 30 if( (device_mode == "SmartPhone" || device_mode == "Tablet") && respons_flg ){ 31 //alert('mode = ' + device_mode); 32 var viewport = document.querySelector('meta[name="viewport"]'); 33 if(uaMcn == 'Android2'){ 34 viewport.setAttribute('content', 'width=device-width, initial-scale=1.0, maximum-scale=2.0, user-scalable=0'); 35 }/*else{ 36 viewport.setAttribute('content', 'width=device-width, initial-scale=1.0, minimal-ui'); 37 }*/ 38 } 39 40 if(device_mode == "SmartPhone"){ 41 //ã¹ããå¦ç 42 //telLink 43 $('.telLink > span').each(function(index, element) { 44 $(element).replaceWith(function() { 45 $(this).replaceWith('<a href="tel:'+$(this).parent('.telLink').attr('data-tel')+'">'+$(this).html()+'</a>'); 46 }); 47 }); 48 } 49 50 //bodyã«uaå¤å®IDãä»ä¸ 51 $('body').attr("id", uaMcn); //id=iPhone 52 $('body').addClass("ver_" + uaVer); //class=ver_8_3_1 53 $('body').addClass(device_mode.toLowerCase()); //class=pc 54 55 56 //window_pixels 57 var wh_obj = $.window_wh_val(); 58 59 60 //ç»é¢å¹ ãã¨ã®å¦ç 61 var menubars = $("#header").innerHeight() + 0; 62 $(window).on('load orientationchange resize',function(){ 63 //Re:window_pixels 64 wh_obj = $.window_wh_val(); 65 //console.log(wh_obj.windowW); 66 67 //retop 68 ããmenubars = $("#header").innerHeight() + 0; 69 }); 70 71 72 /* 73 var windflg = (wh_obj.windowW < size_sp) ? false : true; 74 var clone_flg = (wh_obj.windowW >= size_tb && wh_obj.windowW < size_pc - 1) ? false : true; 75 $(window).on('load orientationchange resize',function(){ 76 //Re:window_pixels 77 wh_obj = $.window_wh_val(); 78 //console.log(wh_obj.windowW); 79 }); 80 */ 81 82 83 //menu 84 $(window).scroll(function () { 85 //console.log(menubars + ' : scr = ' + $(window).scrollTop()); 86 if(wh_obj.windowW < size_sp && respons_flg){ 87 if($(window).scrollTop() < menubars){ 88 $("#menu").removeClass("fixed-bottom"); 89 }else{ 90 $("#menu").addClass("fixed-bottom"); 91 } 92 } 93 }); 94 95 96 $("body").on("click", "#menu_btn > a, #container.on > #mnBack", function(e){ 97 e.preventDefault(); 98 menu_open_close(); 99 }); 100 $("body").on("click", "#menu > #global > li a", function(e){ 101 if($.url($(this).attr('href')).attr('fragment')){ 102 var flgmnt = "#" + $.url($(this).attr('href')).attr('fragment'); 103 //alert('id = ' + id + ' : flg = ' + flgmnt); 104 e.preventDefault(); 105 if($(flgmnt).length > 0){ 106 scrl(flgmnt, 400); 107 }else{ 108 scrl('body'); 109 } 110 menu_open_close(); 111 } 112 }); 113 114 115 //page_anchor 116 $("body").on("click", ".page_anchor_wrap a", function(e){ 117 if($.url($(this).attr('href')).attr('fragment')){ 118 var flgmnt = "#" + $.url($(this).attr('href')).attr('fragment'); 119 //alert('id = ' + id + ' : flg = ' + flgmnt); 120 e.preventDefault(); 121 if($(flgmnt).length > 0){ 122 scrl(flgmnt, 400); 123 }else{ 124 scrl('body'); 125 } 126 } 127 }); 128 129 130 131 132 //anker 133 var top_url = $.url().param('scrl'); 134 var now_addr_url = $.url().attr('protocol') + '://' + $.url().attr('host') + $.url().attr('path'); 135 if(!top_url && $.url().attr('fragment')){ 136 top_url = $.url().attr('fragment'); 137 } 138 if(top_url){ 139 setTimeout(function(){ 140 scrl('#' + top_url, 0); 141 history.replaceState('','',now_addr_url); 142 }, 200); 143 } 144 145 146 function scrl(ank, speed){ 147 if(!speed){ 148 var speed_in = 0; 149 }else{ 150 var speed_in = speed; 151 } 152 var head_heights = 50; 153 if(wh_obj.windowW >= size_pc){ 154 head_heights = 0; 155 } 156 157 var pos = $(ank).offset().top - head_heights; 158 $("html, body").animate({scrollTop: pos}, speed_in, "swing"); 159 } 160 161 function menu_open_close(){ 162 if($("#menu_btn > a.on").length){ 163 $("#menu_btn > a").removeClass('on'); 164 if($("#menu.off").length < 1) { 165 $("#menu").removeClass('on'); 166 $("#menu").addClass('off'); 167 } 168 $("#container").attr('class', 'off'); 169 }else{ 170 $("#menu_btn > a").addClass('on'); 171 if($("#menu.on").length < 1) { 172 $("#menu").removeClass('off'); 173 $("#menu").addClass('on'); 174 } 175 $("#container").attr('class', 'on'); 176 } 177 } 178 179 //pager 180 if($(".pager").length > 0){ 181 $("body").on("click", ".pager .pagination li a", function(e){ 182 e.preventDefault(); 183 184 if($(this).attr('class') != 'disable'){ 185 var now = parseInt($("#nowpagevalue").val(), 10); 186 var linum = 0; 187 if($(this).parent('li').attr('class') == 'pre'){ 188 linum = now - 1; 189 } 190 else if($(this).parent('li').attr('class') == 'next'){ 191 linum = now + 1; 192 } 193 else { 194 linum = parseInt($(this).find('span').text(), 10) - 1; 195 } 196 $("#pagevalue").val(linum); 197 $("#page_navigator").submit(); 198 } 199 }); 200 } 201 202 203 204 //anime_start 205 /* 206 var scrollTopVal = $(window).scrollTop() + wh_obj.windowH; 207 208 if($('.section').length > 0){ 209 $('.section').each(function(ind, elem){ 210 var tgt_parent_st = $(elem).parent(); 211 var tgt_offtop_st = tgt_parent_st.offset().top + 100; 212 if(scrollTopVal > tgt_offtop_st){ 213 tgt_parent_st.attr('data-anime_flag', 'on'); 214 }else{ 215 tgt_parent_st.attr('data-anime_flag', 'off'); 216 } 217 }); 218 if($('.section .anime_item').length > 0){ 219 $('.section .anime_item').each(function(ind2, elem2){ 220 var tgt_item_offtop_st = $(elem2).offset().top + 100; 221 if(scrollTopVal > tgt_item_offtop_st){ 222 $(elem2).attr('data-anime_flag', 'on'); 223 }else{ 224 $(elem2).attr('data-anime_flag', 'off'); 225 } 226 }); 227 } 228 } 229 230 $(window).scroll(function () { 231 //anime 232 scrollTopVal = $(window).scrollTop() + wh_obj.windowH; 233 234 if($('.section').length > 0){ 235 $(':not([data-anime_flag="on"]) .section').each(function(ind, elem){ 236 var tgt_parent = $(elem).parent(); 237 var tgt_offtop = tgt_parent.offset().top + 100; 238 if(scrollTopVal > tgt_offtop){ 239 tgt_parent.attr('data-anime_flag', 'on'); 240 } 241 }); 242 if($('[data-anime_flag="on"] .section .anime_item').length > 0){ 243 $('[data-anime_flag="on"] .section .anime_item').each(function(ind2, elem2){ 244 var tgt_item_offtop = $(elem2).offset().top + 100; 245 if(scrollTopVal > tgt_item_offtop){ 246 $(elem2).attr('data-anime_flag', 'on'); 247 } 248 }); 249 } 250 } 251 }); 252 */ 253}); 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268
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.