
function connexionWindow()
{new MochaUI.Window({id:'connexionWindow',loadMethod:'xhr',contentURL:'template/connexionWindow.php',title:lang.windows.connexion.title,type:'modal',resizable:false,maximizable:false,collapsible:false,width:300,height:135,footerHeight:5,evalScripts:true,evalResponse:true,icon:'design/icons/key.png',onContentLoaded:function(){try{$('userField').focus();}catch(e){}}});}
function aboutWindow()
{new MochaUI.Window({id:'aboutWindow',loadMethod:'xhr',contentURL:'template/infoWindow.php',title:'A propos',type:'modal',resizable:false,maximizable:false,collapsible:false,width:300,height:200,footerHeight:5,icon:'design/icons/info.png'});}
function helpWindow()
{new MochaUI.Window({id:'helpWindow',loadMethod:'iframe',contentURL:pathDoc,title:lang.windows.help.title,type:'window',resizable:true,maximizable:true,collapsible:true,width:800,height:300,footerHeight:5,icon:'design/icons/help.png'});}
function closeWindow(id)
{if($(id))
MochaUI.closeWindow($(id));}
function alertWindow(txt,type)
{alert(type+' : '+txt);lowerType=type;txt='<div class="'+lowerType.toLowerCase()+'">'+txt+'</div><input id="alertButton" type="button" onclick="MochaUI.closeWindow($(\'alertWindow\'))" value="OK"/>';txt='<div class="alert">'+txt+'</div>';}
function uploadWindow()
{new MochaUI.Window({id:'uploadWindow',loadMethod:'xhr',contentURL:'template/upload/fancyUpload.php?dossier=1',title:lang.windows.upload.title,type:'window',width:490,height:500,footerHeight:5,evalScripts:true,evalResponse:true,icon:'design/icons/upload.png',onClose:function()
{$('uploadWindow_content').destroy();}});}