/*
 *	この辺はメニュー用の設定
 */
function loadMenus()
{
	if(window.chiiki)  return;
	window.chiiki = new Menu("", 140, 20, "", 11, "#000000","#330099","#ccffcc","#ffffcc","left", "middle", 0, 0, 200, 0, 0, true, true, true, 5, false, false);
	chiiki.addMenuItem("盛岡", "location = 'center.php?blogid=3'");
	chiiki.addMenuItem("八幡平", "location = 'center.php?blogid=4'");
	chiiki.addMenuItem("花巻・北上・遠野", "location = 'center.php?blogid=5'");
	chiiki.addMenuItem("奥州", "location = 'center.php?blogid=6'");
	chiiki.addMenuItem("一関", "location = 'center.php?blogid=7'");
	chiiki.addMenuItem("大船渡・釜石", "location = 'center.php?blogid=8'");
	chiiki.addMenuItem("宮古", "location = 'center.php?blogid=9'");
	chiiki.addMenuItem("久慈", "location = 'center.php?blogid=10'");
	chiiki.addMenuItem("二戸", "location = 'center.php?blogid=11'");
	chiiki.fontWeight="bold";
	chiiki.hideOnMouseOut = true
	chiiki.menuBorder = 1;
	chiiki.menuLiteBgColor = '#ffffff';
	chiiki.menuBorderBgColor = '#c0d0ee';
	chiiki.bgColor = '#ffffff';

	if(window.sakumotsu)  return;
	window.sakumotsu = new Menu("", 140, 20, "", 11, "#000000","#330099","#ccffcc","#ffffcc","left", "middle", 0, 0, 200, 0, 0, true, true, true, 5, false, false);
	sakumotsu.addMenuItem("水稲", "location = 'catitemlist.php?catid=5&subcatid=13'");
	sakumotsu.addMenuItem("畑作物", "location = 'catitemlist.php?catid=5&subcatid=14'");
	sakumotsu.addMenuItem("野菜", "location = 'catitemlist.php?catid=5&subcatid=15'");
	sakumotsu.addMenuItem("花き", "location = 'catitemlist.php?catid=5&subcatid=16'");
	sakumotsu.addMenuItem("果樹", "location = 'catitemlist.php?catid=5&subcatid=17'");
	sakumotsu.addMenuItem("畜産", "location = 'catitemlist.php?catid=5&subcatid=18'");
	sakumotsu.addMenuItem("農業経営", "location = 'catitemlist.php?catid=5&subcatid=19'");
	sakumotsu.addMenuItem("集落営農", "location = 'catitemlist.php?catid=5&subcatid=20'");
	sakumotsu.addMenuItem("就農・青少年", "location = 'catitemlist.php?catid=5&subcatid=21'");
	sakumotsu.addMenuItem("起業・地域資源活用", "location = 'catitemlist.php?catid=5&subcatid=22'");
	sakumotsu.addMenuItem("男女共同参画", "location = 'catitemlist.php?catid=5&subcatid=23'");

	sakumotsu.fontWeight="bold";
	sakumotsu.hideOnMouseOut = true
	sakumotsu.menuBorder = 1;
	sakumotsu.menuLiteBgColor = '#ffffff';
	sakumotsu.menuBorderBgColor = '#c0d0ee';
	sakumotsu.bgColor = '#ffffff';



	window.writeMenus();
}



function getTableWidth()
{
	var width = getInnerWidth();
	if(width > 760)  return 760;
	return '100%';
}



function getInnerWidth()
{
	var width = 0;
	if(document.layers)  width = window.innerWidth
	if(document.all)	 width = document.body.clientWidth
	return width;
}


function MM_swapImgRestore() { //v3.0
	var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}



function MM_preloadImages() { //v3.0
	var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
	var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
	if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}



function MM_findObj(n, d) { //v4.0
	var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
		d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
	if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
	for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
	if(!x && document.getElementById) x=document.getElementById(n); return x;
}



function MM_swapImage() { //v3.0
	var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
	if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

