
if(!window.Msn){
	window.Msn=new Object();
	}

Msn.InfoPane=new function(){
	var me=this;
	var se=null;
	var t=null;
	var dly=8;
	var tm=1;
	var st=0;
	var w=window;
	var dots = new Array();
	dots = ['<strong style="font-size:12px;">&bull;</strong>','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;','&bull;'];
	
	if(w.ipFadeSecs){
		tm=w.ipFadeSecs;
		}
	if(w.ipDelaySecs){
		dly=w.ipDelaySecs;
		}
	function E(id){
		return document.getElementById(id);
		}
	function ol(){
		if(!se&&ct()){
			res();
			}
		}
	function init(){
		if(!se){
			var ss=E('slideshow');
			if(ss){
				se=fc(ss);
				if(se){
					ss.onmousemove=pause;
					ss.onfilterchange=trans;
					}
				}
			}
		}
	function uninit(){
		var ss=E('slideshow');
		if(ss){
			ss.onfilterchange=null;
			ss.onmousemove=null;
			}
		}
	function hide(){
		st=1;
		var ss=E('slideshow');
		if(ss.filters&&ss.filters[0]){
			f(ss,0);
			}
		else{
			h();
			t=w.setTimeout(trans,tm*1000/4);
			}
		}
	function trans(){
		if(st==1){
			st=2;
			se=ns(se);
			var ss=E('slideshow');
			if(ss.filters&&ss.filters[0]){
				f(ss,1);
				}
			else{
				s();
				res();
				}
			}
		else if(st==2){
			res();
			}
		}
	function res(){
		st=0;
		/*t=w.setTimeout(hide,dly*700);*/
		}
	function ct(){
		w.clearTimeout(t);
		init();
		return(se!==null);
		}
	function f(ss,v){
		ss.filters[0].apply();
		(v?s():h());
		ss.filters[0].play(duration=tm);
		}
	//SHOW
	function s(){
		se.style.display="block";
		}
	//HIDE
	function h(){
		se.style.display="none";
		}
	function pause(){
		if(!st){
			if(ct()){
				res();
				}
			}
		}
	function fc(p){
		var n=p.firstChild;
		while(n&&n.nodeType!=1){
			n=n.nextSibling;
			}
		return n;
		}
	function lc(p){
		var n=p.lastChild;
		while(n&&n.nodeType!=1){
			n=n.previousSibling;
			}
		return n;
		}
	function pe(n){
		var p=n.parentNode;
		while(p&&p.nodeType!=1){
			p=p.parentNode;
			}
		return p;
		}
	function ns(n){
		var s=n.nextSibling;
		while(s&&s.nodeType!=1){
			s=s.nextSibling;
			}
		if(!s){
			s=fc(pe(n));
			}
		return s;
		}
	function ps(n){
		var s=n.previousSibling;
		while(s&&s.nodeType!=1){
			s=s.previousSibling;
			}
		if(!s){
			s=lc(pe(n));
			}
		return s;
		}
	/*-----*/
	this.Flip=function(r){
		if(!st){
			if(ct()){
				var arr = '';
				h();
				se=(r?ps(se):ns(se));
				s();
				res();
				if(r){arr = dots.shift();dots.push(arr)}else{arr = dots.pop();dots.reverse();dots.push(arr);dots.reverse();};
				document.getElementById('dot').innerHTML=dots.join(' ');
				}
			}
		if(w.event){
			w.event.returnValue=false;
			}
		return false;
		};
	/*-----*/
	this.oncreate=function(){
		if(w.attachEvent){
			w.attachEvent("onload",ol);
			w.attachEvent("onunload",me.ondestroy);
			}
		else{
			w.addEventListener("load",ol,false);
			}
		};
	/*-----*/
	this.ondestroy=function(){
		if(w.detachEvent){
			w.detachEvent("onunload",me.ondestroy);
			w.detachEvent("onload",ol);
			uninit();
			}
		};
	this.oncreate();
	return this;
	};

function flip(r){
	if(Msn&&Msn.InfoPane){
		Msn.InfoPane.Flip(r);
		}
	}