/* /////////////////////////////////////////////////////////////////////////

title:   entropy.js
author:  Case
url:     -
outline: BB Entropy Image Banner JS.
version: 2.1
date:    18/03/2006
update:  23/05/2010

///////////////////////////////////////////////////////////////////////// */

/*
/// 2010/12/14 追記 /////////////////////////////

文字コードと改行コードに注意!!!

基本的に「UTF-8」「LF」以外は使用しない!!!

BBのサイトは基本的に上記のコードで作成してます。

外部ファイルを読込む場合など、文字コードや改行コードが違う場合、
正しく動作しなくなる場合があります。


*/
//				{ src: 'image/top/entropy_w/06.jpg', name:'bnr', title:'' },



$(function(){
	$("#entropy").imageLoader(
		{
			splashScreenImage: "../image/top/entropy_w/loader_tm.png",
			images: [
				{ src: 'image/top/entropy_w/00.gif', name:'bnr', title:'' },
				{ src: 'image/top/entropy_w/01.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/03.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/04.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/06.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/09.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/10.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/12.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/15.jpg', name:'foto', title:'' },
				{ src: 'image/top/entropy_w/17.jpg', name:'foto', title:'' }
			]
		},
		function(){
			$('#entropybadges').show(
				0,
				function(){
					$("#entropy_maxslide").hide(0);//00jpg対応
					$("#entropy_button").hide(0);
					$("#entropy_badge").hide(0);
					$('#entropy').cycle({
						fx: 'fade',
        				speed: 1500, 
						timeoutFn: function(currElement, nextElement) {
							if (nextElement.name == 'bnr') {
								//timeouts = 7000;
								timeouts = 1000;
							}else{
								timeouts = 3000;
							}
							return timeouts;
						},
						before: function() {
							if ( this.name == 'bnr' ) {
								$("#entropybadges").hide(0);
								//$("#entropybadges_yata").show(0);//八咫烏　内覧会　透明png
								$("#entropybadges_yata").hide(0);//八咫烏　内覧会　透明png

							} else {
								$("#entropybadges").show(0);
								$("#entropy_maxslide").hide(0);//00jpg対応
								$("#entropy_button").hide(0);
								$("#entropy_badge").show(0);
								$("#entropybadges_yata").hide(0);//八咫烏　内覧会　透明png
							}
						}
					});
				}
			);
		}

	);
});

$(function(){
	$("#line_text").imageLoader(
		{
			endableSplashScreen: null,
			images: [
				{ src: 'image/top/entropy_w/lines/01_jisin.png', title:'' },
				{ src: 'image/top/entropy_w/lines/01_jisin.png', title:'' }
			]
		});
});


/*
$(function(){
	$("#line_text").imageLoader(
		{
			endableSplashScreen: null,
			images: [
				{ src: 'image/top/entropy_w/lines/01.png', title:'' },
				{ src: 'image/top/entropy_w/lines/02.png', title:'' },
				{ src: 'image/top/entropy_w/lines/03.png', title:'' },
				{ src: 'image/top/entropy_w/lines/04.png', title:'' },
				{ src: 'image/top/entropy_w/lines/05.png', title:'' },
				{ src: 'image/top/entropy_w/lines/06.png', title:'' },
				{ src: 'image/top/entropy_w/lines/07.png', title:'' },
				{ src: 'image/top/entropy_w/lines/08.png', title:'' },
				{ src: 'image/top/entropy_w/lines/09.png', title:'' },
				{ src: 'image/top/entropy_w/lines/10.png', title:'' },
				{ src: 'image/top/entropy_w/lines/11.png', title:'' },
				{ src: 'image/top/entropy_w/lines/12.png', title:'' },
				{ src: 'image/top/entropy_w/lines/13.png', title:'' },
				{ src: 'image/top/entropy_w/lines/14.png', title:'' },
				{ src: 'image/top/entropy_w/lines/15.png', title:'' },
				{ src: 'image/top/entropy_w/lines/16.png', title:'' },
				{ src: 'image/top/entropy_w/lines/17.png', title:'' },
				{ src: 'image/top/entropy_w/lines/18.png', title:'' },
				{ src: 'image/top/entropy_w/lines/19.png', title:'' },
				{ src: 'image/top/entropy_w/lines/20.png', title:'' },
				{ src: 'image/top/entropy_w/lines/21.png', title:'' },
				{ src: 'image/top/entropy_w/lines/22.png', title:'' },
				{ src: 'image/top/entropy_w/lines/23.png', title:'' }
			]
		});
});
*/


$(function(){
	$('.shiftlines').click(function(){
		$('#entropy').cycle('pause');
		$('#entropy, #entropybadges').hide(0);
		$('#lines').show(0);
		$('#line_text').cycle({
//			fx: 'scrollDown',
			fx: 'fade',
//			easing: 'bounceout',
//			delay:  -2000,
			timeout: 5000,//timeout: 5000,
//			random: 1,
			autostop: 1,
			end: function() {
				$('#lines').hide(0);
				$('#entropy, #entropybadges').show(0);
				$('#entropy').cycle(0);
				$('#entropy').cycle('resume');
			}
		});
	});
});

$(function(){
	$('.shiftentropy').click(function(){
		$('#line_text').cycle('pause');
		$('#lines').hide(0);
		$('#entropy, #entropybadges').show(0);
		$('#entropy').cycle(0);
		$('#entropy').cycle('resume');
		return false;
	});
});


