
//初期処理

//$関数はjQueryとしてではなく、他のライブラリで定義された$関数として動作する
	jQuery.noConflict();
	jQuery(function($){
		
		//*------------------------------------------------------------*//
		//サービスリストをjavascriptで非表示(DreamWearverで編集する為)
		//*------------------------------------------------------------*//
		$("#serviceListDialogWrapper").hide();
		
		//*------------------------------------------------------------*//
		//サービスリストのジャンルをタブで切り替える処理
		//*------------------------------------------------------------*//
		$("#serviceMenu01, #serviceMenu02, #serviceMenu03").hide();
		$("#serviceMenu01").show();
		$("#serviceListDialog .tab01 img").css("opacity",0);
		
		$("#serviceListDialog .tab01").mouseover(function(){
			$("#serviceMenu01, #serviceMenu02, #serviceMenu03").hide();
			$("#serviceMenu01").show();
			$("#serviceListDialog .tab01 img, #serviceListDialog .tab02 img, #serviceListDialog .tab03 img").css("opacity",1);
			$("#serviceListDialog .tab01 img").css("opacity",0);
		});
		$("#serviceListDialog .tab02").mouseover(function(){
			$("#serviceMenu01, #serviceMenu02, #serviceMenu03").hide();
			$("#serviceMenu02").show();
			$("#serviceListDialog .tab01 img, #serviceListDialog .tab02 img, #serviceListDialog .tab03 img").css("opacity",1);
			$("#serviceListDialog .tab02 img").css("opacity",0);
		});
		$("#serviceListDialog .tab03").mouseover(function(){
			$("#serviceMenu01, #serviceMenu02, #serviceMenu03").hide();
			$("#serviceMenu03").show();
			$("#serviceListDialog .tab01 img, #serviceListDialog .tab02 img, #serviceListDialog .tab03 img").css("opacity",1);
			$("#serviceListDialog .tab03 img").css("opacity",0);
		});
		
		
		//*------------------------------------------------------------*//
		//FIXEDグループのマウスオーバー処理
		//*------------------------------------------------------------*//
		$("#fixedGroup a").hover(
			function(){
			
			$(this).animate({
				right : "0px"
			},100);
		},function(){
		
			$(this).animate({
				right : "-3px"
			});
		});
		
		//var r = 0;
		//setInterval(function(){
		//	
		//	if ( r % 2 ) {
		//		$("#twitter").animate( {
		//			backgroundPosition: '0px 0px'
		//		} ,500);
		//	} else {
		//		$("#twitter").animate( {
		//			backgroundPosition: '-33px 0px'
		//		} ,500);
		//	}
		//	r++;
		//}, 2000);
		
		$("#twitter").hover(function(){
			
			$("#twitterArea").show("fast");
			
		},function(){
			
			$("#twitterArea").hide("fast");
			
		});
		
		
		//*------------------------------------------------------------*//
		//g_menuグループのマウスオーバー処理
		//*------------------------------------------------------------*//
		//$("#g_menu li").hover(
		//	function(){
		//	
		//	$("a",this).css("position","relative").animate({
		//		top : "5px"
		//	},100);
		//},function(){
		//
		//	$("a",this).animate({
		//		top : "0"
		//	},100);
		//});
		//
		////*------------------------------------------------------------*//
		////footerMenuグループのマウスオーバー処理
		////*------------------------------------------------------------*//
		//$("#footer ul li").hover(
		//	function(){
		//	
		//	$("a",this).css("position","relative").animate({
		//		top : "-5px"
		//	},100);
		//},function(){
		//
		//	$("a",this).animate({
		//		top : "0"
		//	},100);
		//});
		jQuery("#g_menu a img, #footer a img").hover(function(){
			jQuery(this).animate({opacity:0},300);
		},function(){
			jQuery(this).animate({opacity:1},0);
		});
		
		
		////*------------------------------------------------------------*//
		////サイドバーのスライドバナー（資料請求、お客様の声）マウスオーバー処理
		////*------------------------------------------------------------*//
		$('ul.hover_block li').hover(function(){
			$(this).find('img').animate({left:'-62px'},{queue:false,duration:500});
			}, function(){
			$(this).find('img').animate({left:'0px'},{queue:false,duration:500});
		});

		////*------------------------------------------------------------*//
		////サイドバーのスライドバナー（おかげさまで創業100年等）マウスオーバー処理
		////*------------------------------------------------------------*//
		//var INTERVAL = 3000; //3.5秒
		//
		//setInterval(function(){
		//	//バナーの数-1をi<●の部分に数値を設定する
		//	for( i=1; i<6; i++ ){
		//		//i－１の値を i==◯の部分に数値を設定する
		//		if(i == 5){
		//			j = 1;
		//		} else {
		//			j = i + 1;
		//		}
		//		if( jQuery("#cm"+i).css("display") != "none" ){
		//			jQuery("#cm"+i).animate({ width:"-=205px" },{complete:function(){ jQuery("#cm"+i).hide();}});
		//			jQuery( "#cm"+j ).css( "left","205px").css("width","0px").show().animate({ width: "+=205px", left: "-=205px" }, "slow" );
		//			break;
		//		}
		//		
		//	}
		//},INTERVAL);

		////*------------------------------------------------------------*//
		////サイドの固定ナビ（お問合わせ、サービス一覧など）マウスオーバー処理
		////*------------------------------------------------------------*//
		$("#inqCom").hide(); 
		$("#serCom").hide(); 
		$("#inquiry").hover(function(){ 
			//mouseover 
			$("#inqCom").show(); 
		}, function() { 
			//mouseout 
			$("#inqCom").hide(); 
		}); 
		$("#serviceList").hover(function(){ 
			//mouseover 
			$("#serCom").show(); 
		}, function() { 
			//mouseout 
			$("#serCom").hide(); 
		}); 

		////*------------------------------------------------------------*//
		////トップページの左側の見出し（中小企業の～等）マウスオーバー処理
		////*------------------------------------------------------------*//
		$(".leftMenu a").hover(function(){
			$(this).animate({left : "-25px"},100);
		},function(){			
			$(this).animate({left : "-30px"});
		});
		
	});
// スコープの外では、他のライブラリで定義された$関数として動作する


// フラッシュコンテンツの表示（ヘッダー部とメイン部）
function flashContents(num){
	var flashvars = {};
	var params = {};
	params.play = "true";
	params.loop = "true";
	params.menu = "true";
	params.quality = "high";
	params.scale = "noscale";
	params.salign = "";
	params.wmode = "transparent";
	params.bgcolor = "#ffffff";
	params.devicefont = "false";
	params.allowfullscreen = "true";
	params.allowscriptaccess = "sameDomain";
	var attributes = {};
	
	switch (num){
		case 0 : //メイン部１
			//attributes.id = "02pageFlashVer02";
			//attributes.align = "middle";
			//swfobject.embedSWF("/wp-content/themes/asahiinsatsu/flash/mainFlashLogo.swf", "mainFlash", "100%", "380", "9.0.0", "expressInstall.swf", flashvars, params, attributes);
			break;
		case 1 : //メイン部２
			attributes.id = "02pageFlashVer03";
			attributes.align = "middle";
			swfobject.embedSWF("/wp-content/themes/asahiinsatsu/flash/02pageFlashVer03.swf", "mainFlash", "100%", "420", "9.0.0", "expressInstall.swf", flashvars, params, attributes);
			break;
		case 2 : //ヘッダー部
			attributes.id = "topMsg";
			attributes.align = "middle";
			swfobject.embedSWF("/wp-content/themes/asahiinsatsu/flash/topMsgFlash.swf", "topMsg", "100%", "60", "9.0.0", "expressInstall.swf", flashvars, params, attributes);
			break;
	}
		
}


// ------------------------------------------------------------
// HTML HIGHSLIDE.JS
// ------------------------------------------------------------

function openHtmlHighSlide(opener, width, height) {

    var returnValue;
    returnValue = hs.htmlExpand(opener, { 
        objectType: 'ajax',
        width: width, 
        height: height,
        allowSizeReduction: false,
        wrapperClassName: 'draggable-header no-footer'
    });
    
    return returnValue;
}
// ------------------------------------------------------------
// HTML HIGHSLIDE.JS end
// ------------------------------------------------------------


