window.onload = function() {
	n=new nFlash();n.setNot(1);n.setMax(1);
}

function nFlash() {
	this.not = 1;
	this.maxNot = 5;
	
	this.setNot = function(not) {
		document.getElementById('nflash_l' + this.not).style.display = 
		document.getElementById('nflash_t' + this.not).style.display = 'none';
		
		this.not = not;
		
		document.getElementById('nflash_l' + not).style.display =
		document.getElementById('nflash_t' + not).style.display = 'block';
	}
	this.setMax = function(m){ this.maxNot=m; }
	
	this.prevNot = function() {
		var c = this.not - 1;
		if(c < 1) c=this.maxNot;
		this.setNot(c);
	}
	this.nextNot = function() {
		var c = this.not + 1;
		if(c > this.maxNot) c=1;
		this.setNot(c);
	}
}
