// JavaScript Document
var bauto = 0;
var dossier="images";
var numero = 1;
		
function objet() {
	this.length = objet.arguments.length
	for (var i = 0; i < this.length; i++)
		this[i+1] = objet.arguments[i]
}
		
var nom = new objet ("nocturne1.jpg", "nocturne2.jpg", "nocturne3.jpg", "nocturne4.jpg", "nocturne5.jpg", "nocturne6.jpg");
		
function suivante() {
	numero += 1;
	if (numero == nom.length + 1)
		numero = 1;
	document.image.src = dossier + nom[numero];
}
		
function precedente() {
	numero -= 1;
	if (numero == 0)
		numero = nom.length; 
	document.image.src = dossier + nom[numero];
}
		
function changer() {
	numero += 1;
	if (numero == nom.length + 1)
		numero = 1;
	document.image.src = dossier+nom[numero];
	roll = setTimeout("changer()", 1500);
}
		
function initial() {
	window.clearTimeout(roll);
	document.image.src = dossier+nom[numero];
}
		
function auto() {
	if (bauto == 0) {
		bauto =1; changer();
		document.vision.automat.value=" Lect/Stop "; 
	} 
	else {
		bauto =0; initial();
		document.vision.automat.value=" Lect/Auto ";
	}
}
