Added close window management and files for goal fonctions