<!--
// DECLARATION DE VARIABLE GLOBALE
var platform;
var browser;
var version;
var adjWidth;
var adjHeight;


// PROPRIETE POUR L OUVERTURE D UN FULL SCREEN SOUS NETSCAPE
windowprops = "top=0,left=0,resizable=yes" + ",width=" + screen.width + ",height=" + screen.height;
// RECUPERATION DE LA VERSION DU BROWSER
version = parseInt(navigator.appVersion);
// RECUPERATION DE LA PLATEFORME + NAVIGATEUR
if(navigator.userAgent.indexOf('Win') == -1) {
	platform = 'Macintosh';
} else {
	platform = 'Windows';
}
if(navigator.appName.indexOf('Netscape') == -1) {
	browser = 'IE';
} else {
	browser = 'Netscape';
}
// AJUSTEMENT DES PROPRIETES POUR LES MAC.
if((platform == 'Macintosh') && (browser == 'Netscape')) {
	adjWidth = 20;
	adjHeight = 35;
}
if((platform == 'Macintosh') && (browser == 'IE')) {
	adjWidth = 20;
	adjHeight = 35;
	winOptions = 'fullscreen=yes';
}
// AJUSTEMENT DES PROPRIETES POUR LES PC.
if((platform == 'Windows') && (browser == 'Netscape')) {
	adjWidth = 12;
	adjHeight = 12;
}
if((platform == 'Windows') && (browser == 'IE')) {
	adjWidth = 10;
	adjHeight = 28;
}

// FONCTION DE LANCEMENT
function launch(newURL, newName, newFeatures, orgName) {
	var remote = open(newURL, newName, newFeatures);
	if (remote.opener == null) {
		remote.opener = window;
	}
	remote.opener.name = orgName;
	return remote;
}
// LANCEMENT PLEIN ECRAN
function LaunchFullScreen(url)
{
	var browser = detectBrowser();
	if (browser == 'browserChrome') {
		window.location = url;
		//window.moveTo(0,0);
		//window.resizeTo(screen.availWidth,screen.availHeight);
	}else{
		var winWidth = screen.availWidth;
		var winHeight = screen.availHeight;
	
		if( (navigator.appName == "Microsoft Internet Explorer")
		  && (platform == 'Macintosh') ) {
			  var fullscreenWindow = window.open(url,'plein','top=0,left=0,width='+screen.width +',height='+screen.height+',menubar=no,resize=no');
		} else {
			// Ecran de taille suffisante
			if((winWidth < 1600)&&((browser == "IE") && (version >= 4))) {
				// Lancement sous IE PC vers. 4 et +
				var fullscreenWindow = launch(url, "main", "channelmode=0,dependent=0,directories=0,fullscreen=1,location=0,menubar=0,resizable=1,scrollbars=0,status=1,toolbar=0", "myWindow");
			} else {
				// Lancement sous netscape
				var fullscreenWindow = window.open(url, "LaunchFullScreen", windowprops);
			}
		}
	
		if (fullscreenWindow == null) alert("vous devez autoriser les pop ups pour voir le contenu de ce site");
	}
}
function detectBrowser() {
	var userAgent = navigator.userAgent.toLowerCase();
	$.browser.chrome = /chrome/.test(navigator.userAgent.toLowerCase());
	// Is this a version of IE?
	if ($.browser.msie) {
		return 'browserIE';
	}
	// Is this a version of Chrome?
	if ($.browser.chrome) {
		// If it is chrome then jQuery thinks it's safari so we have to tell
		// it it isn't
		$.browser.safari = false;
		return 'browserChrome';
	}
	// Is this a version of Safari?
	if ($.browser.safari) {
		// Add the version number
		return 'browserSafari';
	}
	// Is this a version of Mozilla?
	if ($.browser.mozilla) {
		// Is it Firefox?
		if (navigator.userAgent.toLowerCase().indexOf('firefox') != -1) {
			return 'browserFirefox';
		}
		// If not then it must be another Mozilla
		else {
			return 'browserMozilla';
		}
	}
	// Is this a version of Opera?
	if ($.browser.opera) {
		return 'browserOpera';

	}
}

