/* READY
------------------------------------------------*/
$(document).ready(function() {
	/* トップ用タブコンテンツ */
	$(".xtab").each(function(){
		$(this).addClass("hidetab") ;
		targetID = $(this).attr("title").split("/") ;
		$(targetID[0]).hide() ;
		if( targetID[1]=='show' ){
			$(targetID[0]).show() ;
			$(this).removeClass("hidetab").addClass("showtab") ;
		}
	})
 ;}) ;

/* UTIL
------------------------------------------------*/
$(function() {
	/* マップシステム */
	defaultSel();

	/* プレロード（地図） */
	$.preloadImages(
		'img/mainmap02.gif',
		'img/mainmap03.gif',
		'img/mainmap05.gif',
		'img/mainmap04.gif',
		'img/mainmap06.gif',
		'img/mainmap07.gif',
		'img/mainmap08.gif',
		'img/mainmap09.gif',
		'img/mainmap10.gif'
	);

	/* トップ用タブコンテンツ */
	$(".xtab").click(function(){
		$(".xtab").each(function(){
			targetID = $(this).attr("title").split("/") ;
			$(targetID[0]).hide() ;
			$(this).removeClass("showtab").addClass("hidetab") ;
		}) ;
		targetID = $(this).attr("title").split("/") ;
		$(targetID[0]).show() ;
		$(this).removeClass("hidetab").addClass("showtab") ;
	}) ;

	$(".xtab").hover(
		function(){ $(this).css('cursor','pointer'); },
		function(){ $(this).css('cursor','default'); }
	) ;

});

