window.addEvent('domready', function(){

	new SmoothScroll({wait:false, duration:1500, transition:Fx.Transitions.Back.easeInOut});

});

window.addEvent('domready', function() {
	
	if ( $$('.infobulle') ) {
		var infobulle = new Tips($$('.infobulle'), {
			className: 'bulle',
			offsets: {'x': 5, 'y': -80} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobulle').store('tip:title', 'En savoir plus');
		$$('.infobulle').store('tip:text', 'Ouvrir la popup');

	}
	
	
	if ( $$('.infobulle2') ) {
		var infobulle = new Tips($$('.infobulle2'), {
			className: 'bulle2',
			offsets: {'x': 5, 'y': -80} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobulle2').store('tip:title', 'Bande Annonce');
		$$('.infobulle2').store('tip:text', 'Voir la vidéo');

	}
	
	if ( $$('.infobulle3') ) {
		var infobulle = new Tips($$('.infobulle3'), {
			className: 'bulleContact',
			offsets: {'x': 5, 'y': -40} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobulle3').store('tip:title', 'Contact');
		$$('.infobulle3').store('tip:text', '<strong>Organisation &amp; Partenariats</strong><br />Jean-Louis Sevez Organisation<br />Tél. 04 79 52 10 00<br />info@jlso.fr<br /><br />	<strong>Relations Publiques Relations Presse</strong><br />Laurence Phitoussi Communication<br />Tél. 01 58 18 60 30<br />feo@phitoussicom.com');
		
	}
	
	
	
	if ( $$('.infobulleAnnonce') ) {
		var infobulle = new Tips($$('.infobulleAnnonce'), {
			className: 'bulleAnnonce',
			offsets: {'x': 5, 'y': -80} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobulleAnnonce').store('tip:title', 'Palmar&egrave;s');
		$$('.infobulleAnnonce').store('tip:text', 'D&eacute;couvrez le palmar&egrave;s en images');

	}
	
	if ( $$('.infobulleDiaporama') ) {
		var infobulle = new Tips($$('.infobulleDiaporama'), {
			className: 'bulleDiaporama',
			offsets: {'x': 5, 'y': -80} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobulleDiaporama').store('tip:title', 'Photos');
		$$('.infobulleDiaporama').store('tip:text', 'Revivez l\'&eacute;dition 2010 en photos');

	}
	
	if ( $$('.infobullePartenaire') ) {
		var infobulle = new Tips($$('.infobullePartenaire'), {
			className: 'bulleDiaporama',
			offsets: {'x': 5, 'y': -80} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobullePartenaire').store('tip:title', 'Partenaire');
		$$('.infobullePartenaire').store('tip:text', 'En savoir plus sur ce partenaire');

	}
	
	if ( $$('.infobullePalmares') ) {
		var infobulle = new Tips($$('.infobullePalmares'), {
			className: 'bulleDiaporama',
			offsets: {'x': 5, 'y': -80} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobullePalmares').store('tip:title', 'Palmarès');
		$$('.infobullePalmares').store('tip:text', 'Télécharger le fichier PDF');

	}
	
	if ( $$('.infobulleComite') ) {
		var infobulle = new Tips($$('.infobulleComite'), {
			className: 'bulleDiaporama',
			offsets: {'x': 5, 'y': -80} /* Position de la bulle par rapport à la souris */
		});
		infobulle.addEvent('show', function(tip){
			tip.set('morph', {duration: 500, transition: Fx.Transitions.linear, wait:false });
		    tip.morph({
				'opacity': [0.1,1],
				'margin-top': [20,1]
			});
		});
		infobulle.addEvent('hide', function(tip){
		    tip.morph({
		    	'opacity': [1,0],
				'margin-top': [1,20]
				
			});
		});
	
		/* Textes : */
		$$('.infobulleComite').store('tip:title', 'Comité');
		$$('.infobulleComite').store('tip:text', 'Découvrez les membres 2010');

	}
	

	
	
	
	
	
	
	
	
	
	if ( $('newsfade_box') ) {
	new viewer($$('#newsfade_box img'), { 
		mode: 'alpha',
		interval: 2500
	}).play(true);
}
});
