if(typeof MFW=='undefined'){var MFW={};};
MFW.window = {
	hrefRE: new RegExp('^http://' + window.location.host),
	name: window.location.host + 'newwindow',
	features: '',
	fenetreAutreDomaine: function() {
		var as = document.getElementsByTagName('a');
		for(var i=0;i<as.length;i++) {
			var a = as[i];
			if(!MFW.window.hrefRE.exec(a.href)) {
				YAHOO.util.Event.addListener(a, 'click', MFW.window.open);
			}
		}
	},
	open: function(e) {
		if(!(e.ctrlKey || e.altKey || e.shiftKey || e.metaKey)) {
			var win=window.open(this.href, MFW.window.name, MFW.window.features);
			if(win) {
				if(window.focus) win.focus();
				YAHOO.util.Event.stopEvent(e);
			}
		}
	},
	init: function() {
		var outer=(self.innerHeight ? true : false),sw=self.screen.availWidth,sh=self.screen.availHeight;
		var w=Math.floor(sw*.8),h=Math.floor(sh*.8);
		var l=Math.floor((sw-w)/2),t=Math.floor((sh-h)/2);
		MFW.window.features='top='+t+',left='+l+','+(outer ? 'outerWidth' : 'width')+'='+w+','+(outer ? 'outerHeight' : 'height')+'='+h+',menubar=yes,toolbar=yes,location=yes,directories=yes,personalbar=yes,status=yes,resizable=yes,scrollbars=yes';
	}
};
MFW.window.init();

