diff --git a/Common/Options.cpp b/Common/Options.cpp index e3a6a1d2562efc1fd5fb4a45dd8a41b7f90fc1ae..e3ccab762012a4fff732ae5168fc26c175d87e6c 100644 --- a/Common/Options.cpp +++ b/Common/Options.cpp @@ -1,4 +1,4 @@ -// $Id: Options.cpp,v 1.140 2004-04-08 18:12:10 geuzaine Exp $ +// $Id: Options.cpp,v 1.141 2004-04-08 22:14:28 geuzaine Exp $ // // Copyright (C) 1997-2004 C. Geuzaine, J.-F. Remacle // @@ -80,10 +80,8 @@ void Init_Options(int num) // Home directory if((tmp = getenv("GMSH_HOME"))) strcpy(CTX.home_dir, tmp); -#if !defined(WIN32) // Some WinNT systems have bad HOME variables... else if((tmp = getenv("HOME"))) strcpy(CTX.home_dir, tmp); -#endif else if((tmp = getenv("TMP"))) strcpy(CTX.home_dir, tmp); else if((tmp = getenv("TEMP"))) diff --git a/Fltk/Callbacks.cpp b/Fltk/Callbacks.cpp index e4e3f98f2270ee126333229c6efc8bfd90e0cba9..6d89268bda5d04093374d8b02e6e45a245d20dfd 100644 --- a/Fltk/Callbacks.cpp +++ b/Fltk/Callbacks.cpp @@ -1,4 +1,4 @@ -// $Id: Callbacks.cpp,v 1.212 2004-04-01 22:21:36 geuzaine Exp $ +// $Id: Callbacks.cpp,v 1.213 2004-04-08 22:14:28 geuzaine Exp $ // // Copyright (C) 1997-2004 C. Geuzaine, J.-F. Remacle // @@ -97,7 +97,8 @@ int file_chooser(int multi, int create, const char *message, Fl_File_Chooser::all_files_label = "All files (*)"; if(!fc) { - fc = new Fl_File_Chooser(".", pat, Fl_File_Chooser::SINGLE, message); + fc = new Fl_File_Chooser(getenv("PWD") ? "." : CTX.home_dir, pat, + Fl_File_Chooser::SINGLE, message); strncpy(oldfilter, pat, 1024); }