/*
 * This file is part of EC-CUBE
 *
 * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
 *
 * http://www.lockon.co.jp/
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 */
	var preLoadFlag = "false";

	function preLoadImg(URL){

		arrImgList = new Array (
				URL+"image/b_backnext_on.gif",
				URL+"image/b_backnext.gif",
				URL+"image/b_backnext2_on.gif",
				URL+"image/b_backnext2.gif",
				URL+"image/b_backprev_on.gif",
				URL+"image/b_backprev.gif",
				URL+"image/b_backsmall_on.gif",
				URL+"image/b_backsmall.gif",
				URL+"image/b_backsmalllong_on.gif",
				URL+"image/b_backsmalllong.gif",
				URL+"image/b_cartin_on.gif",
				URL+"image/b_cartin.gif",
				URL+"image/b_detail_on.gif",
				URL+"image/b_detail.gif",
				URL+"image/favorite_b_on.gif",
				URL+"image/favorite_b.gif",
				URL+"image/n_01_on.gif",
				URL+"image/n_01.gif",
				URL+"image/n_02_on.gif",
				URL+"image/n_02.gif",
				URL+"image/n_03_on.gif",
				URL+"image/n_03.gif",
				URL+"image/n_04_on.gif",
				URL+"image/n_04.gif",
				URL+"image/n_05_on.gif",
				URL+"image/n_05.gif",
				URL+"image/n_06_on.gif",
				URL+"image/n_06.gif",
				URL+"image/n_07_on.gif",
				URL+"image/n_07.gif",
				URL+"image/n_08_on.gif",
				URL+"image/n_08.gif",
				URL+"image/n_09_on.gif",
				URL+"image/n_09.gif",
				URL+"image/n_10_on.gif",
				URL+"image/n_10.gif",
				URL+"image/n_11_on.gif",
				URL+"image/n_11.gif",
				URL+"image/n_12_on.gif",
				URL+"image/n_12.gif",
				URL+"image/n_13_on.gif",
				URL+"image/n_13.gif",
				URL+"image/n_14_on.gif",
				URL+"image/n_14.gif",
				URL+"image/n_15_on.gif",
				URL+"image/n_15.gif",
				URL+"image/home_on.gif",
				URL+"image/first_on.gif",
				URL+"image/guide_on.gif",
				URL+"image/question_on.gif",
				URL+"image/mypage_on.gif",
				URL+"image/cartin_on.gif"
				);
		arrPreLoad = new Array();
		for (i in arrImgList) {
			arrPreLoad[i] = new Image();
			arrPreLoad[i].src = arrImgList[i];
		}
		preLoadFlag = "true";
	}

	function chgImg(fileName,imgName){
		if (preLoadFlag == "true") {
			document.images[imgName].src = fileName;
		}
	}
	
	function chgImgImageSubmit(fileName,imgObj){
		imgObj.src = fileName;
	}
	
	function chgImgBackground(fileName,imgName,fontColor){
		document.getElementById(imgName).style.backgroundImage="url('" + fileName + "')";
		document.getElementById(imgName).style.color=fontColor;
	}
	// サブナビの表示切替
	function naviStyleChange(ids, bcColor, color){
		document.getElementById(ids).style.backgroundColor = bcColor;
	}	


	
