1/** 2 * Created by Ken on 2015/04/20. 3 */ 4 5$(document).ready(function () { 6 7 var preload_img = [ 8 "/images/common/head_logo_child_history_hover_bg.png", 9 "/images/common/head_logo_child_csr_hover_bg.png", 10 "/images/common/head_logo_child_guid_hover_bg.png", 11 "/images/common/head_logo_child_menu_hover_bg.png", 12 "/images/common/head_logo_child_mugi_hover_bg.png", 13 "/images/common/head_logo_child_picky_hover_bg.png", 14 "/images/common/head_logo_bg_sanki_hover.png", 15 "/images/smartphone/menu_bg.png" 16 ]; 17 18 for(var i=0; i < preload_img.length; i++) { 19 $('<img>').attr('src', TPL_URL + preload_img[i]); 20 } 21 22 23 /** 24 * .img_hover_changeã¯ã©ã¹ãæã¤ã¤ã¡ã¼ã¸ã®ããã¦ã¹ãªã³æã®æåå®ç¾© 25 */ 26 $('img.img_hover_change').hover(function () { 27 $before_src = $(this).attr('src'); 28 $split_str = $before_src.split(/\.(?=[^.]+$)/); //æ¡å¼µååã®é¨åã¨ãæ¡å¼µåã«åå²array["æ¡å¼µåå", "æ¡å¼µå"] 29 30 $newImageSrc = $split_str[0] + "_hover." + $split_str[1]; 31 $(this).attr('src', $newImageSrc); 32 }, function () { 33 34 $before_src = $(this).attr('src'); 35 $split_str = $before_src.split("_hover."); //æ¡å¼µååã®é¨åã¨ãæ¡å¼µåã«åå²array["æ¡å¼µåå", "æ¡å¼µå"] 36 $(this).attr('src', $split_str[0] + "." + $split_str[1]); 37 }); 38 39 $(".drawer").drawer(); 40 $openFlag = false; 41 $('#smart_menu_button_cont a').click(function($e) { 42 $e.preventDefault(); 43 44 if(!$openFlag) { 45 $('.drawer').drawer('toggle'); 46 $openFlag = true; 47 } else { 48 $('.drawer').drawer('close'); 49 $openFlag = false; 50 } 51 52 }); 53 54 $('.drawer').on('drawer.closed', function () { 55 $openFlag = false; 56 }); 57 58 $(window).scroll(function ($e) { 59 $scroll_count = $(window).scrollTop(); 60 $docHeight = $(document).height(); 61 62 $parsetnt = $scroll_count / $docHeight; 63 64 if($parsetnt > 0.4) 65 { 66 67 $('div#to_top').addClass("show"); 68 } else { 69 //to_topé表示 70 71 $('div#to_top').removeClass("show"); 72 } 73 }); 74 75 $('div#to_top').click(function () { 76 $('body, html').animate({ 77 scrollTop : "0" 78 }, 400, "swing") 79 }); 80 81 82 83 84 85});
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.