diff --git a/Fltk/Callbacks.cpp b/Fltk/Callbacks.cpp index edddb46deb3ebcc7a55d64a12ac47dfc89b2bae5..d0f88b4adcea93aa35c3d62072c88cd8ba40ffba 100644 --- a/Fltk/Callbacks.cpp +++ b/Fltk/Callbacks.cpp @@ -1,4 +1,4 @@ -// $Id: Callbacks.cpp,v 1.45 2001-04-29 14:36:44 geuzaine Exp $ +// $Id: Callbacks.cpp,v 1.46 2001-05-01 18:58:24 geuzaine Exp $ #include <map> #include "Gmsh.h" @@ -30,7 +30,7 @@ extern Context_T CTX; int AddViewInUI(int i, char *Name, int Num){ if(i > NB_BUTT_MAX -1) return 1; - if(WID && (WID->get_context() == 2)) + if(WID && (WID->get_context() == 3)) WID->set_context(menu_post,0); return 0; } @@ -498,8 +498,8 @@ void help_short_cb(CALLBACK_ARGS){ Msg(DIRECT, " Alt+o change projection mode"); Msg(DIRECT, " Alt+p hide/show geometry points"); Msg(DIRECT, " Alt+Shift+p hide/show mesh points"); - Msg(DIRECT, " s increase animation delay"); Msg(DIRECT, " Shift+s decrease animation delay"); + Msg(DIRECT, " Ctrl+Shift+s increase animation delay"); Msg(DIRECT, " Alt+s hide/show geometry surfaces"); Msg(DIRECT, " Alt+Shift+s hide/show mesh surfaces"); Msg(DIRECT, " Alt+t alternate intervals mode for all post-processing views"); @@ -528,6 +528,9 @@ void mod_geometry_cb(CALLBACK_ARGS){ void mod_mesh_cb(CALLBACK_ARGS){ WID->set_context(menu_mesh, 0); } +void mod_solver_cb(CALLBACK_ARGS){ + WID->set_context(menu_solver, 0); +} void mod_post_cb(CALLBACK_ARGS){ WID->set_context(menu_post, 0); } @@ -1361,7 +1364,7 @@ void view_remove_cb(CALLBACK_ARGS){ } if(!play) WID->g_status_butt[5]->deactivate(); - if(WID->get_context() == 2) + if(WID->get_context() == 3) WID->set_context(menu_post, 0); if(!REMOVE_ALL_VIEWS) diff --git a/Fltk/Callbacks.h b/Fltk/Callbacks.h index 9aa18611a75807356973e8c4042745d42496b9ad..4cb0d5399cfc8c609d498e41e1558bd571957139 100644 --- a/Fltk/Callbacks.h +++ b/Fltk/Callbacks.h @@ -85,6 +85,7 @@ void help_about_cb(CALLBACK_ARGS) ; void mod_geometry_cb(CALLBACK_ARGS) ; void mod_mesh_cb(CALLBACK_ARGS) ; +void mod_solver_cb(CALLBACK_ARGS) ; void mod_post_cb(CALLBACK_ARGS) ; void mod_back_cb(CALLBACK_ARGS) ; void mod_forward_cb(CALLBACK_ARGS) ; diff --git a/Fltk/Colorbar_Window.cpp b/Fltk/Colorbar_Window.cpp index 74d53a3dde443285cf841b1ccc0ab30fe46b0a69..269067461b40c904ac0ac90617da01f3c4f1c762 100644 --- a/Fltk/Colorbar_Window.cpp +++ b/Fltk/Colorbar_Window.cpp @@ -1,4 +1,4 @@ -// $Id: Colorbar_Window.cpp,v 1.9 2001-02-18 18:04:03 geuzaine Exp $ +// $Id: Colorbar_Window.cpp,v 1.10 2001-05-01 18:58:24 geuzaine Exp $ #include "Gmsh.h" #include "GmshUI.h" @@ -7,7 +7,6 @@ #include "Colorbar_Window.h" #include "Context.h" -extern GUI *WID; extern Context_T CTX; #define UNDEFINED 0 diff --git a/Fltk/GUI.cpp b/Fltk/GUI.cpp index 719917c31a0230d5a828cd7b2ede3f424dbf7f04..47b53b7752cabcddbe748fb2628640d7fe32e3f9 100644 --- a/Fltk/GUI.cpp +++ b/Fltk/GUI.cpp @@ -1,4 +1,4 @@ -// $Id: GUI.cpp,v 1.62 2001-04-22 18:13:02 geuzaine Exp $ +// $Id: GUI.cpp,v 1.63 2001-05-01 18:58:24 geuzaine Exp $ // To make the interface as visually consistent as possible, please: // - use the BH, BW, WB, IW values for button heights/widths, window borders, etc. @@ -77,6 +77,7 @@ Fl_Menu_Item m_menubar_table[] = { Fl_Menu_Item m_module_table[] = { {"Geometry", 'g', (Fl_Callback *)mod_geometry_cb, 0}, {"Mesh", 'm', (Fl_Callback *)mod_mesh_cb, 0}, + {"Solver", 's', (Fl_Callback *)mod_solver_cb, 0}, {"Post-Processing", 'p', (Fl_Callback *)mod_post_cb, 0}, {0} }; @@ -243,8 +244,12 @@ Context_Item menu_mesh[] = { NULL } }; +Context_Item menu_solver[] = +{ { "2Solver", NULL } , + { NULL } }; + Context_Item menu_post[] = -{ { "2Post-Processing", NULL } , +{ { "3Post-Processing", NULL } , { NULL } }; //********************** Definition of global shortcuts ******************************** @@ -285,6 +290,10 @@ int GUI::global_shortcuts(int event){ mod_mesh_cb(0,0); return 1; } + else if(Fl::test_shortcut('s')){ + mod_solver_cb(0,0); + return 1; + } else if(Fl::test_shortcut('p')){ mod_post_cb(0,0); return 1; @@ -305,7 +314,7 @@ int GUI::global_shortcuts(int event){ quit_selection = 1; return 1; } - else if(Fl::test_shortcut('s')){ + else if(Fl::test_shortcut(FL_CTRL+FL_SHIFT+'s')){ opt_post_anim_delay(0,GMSH_SET|GMSH_GUI,opt_post_anim_delay(0,GMSH_GET,0) + 0.01); return 1; } @@ -682,6 +691,7 @@ void GUI::set_context(Context_Item *menu_asked, int flag){ if(menu[0].label[0] == '0') m_module_butt->value(0); else if(menu[0].label[0] == '1') m_module_butt->value(1); else if(menu[0].label[0] == '2') m_module_butt->value(2); + else if(menu[0].label[0] == '3') m_module_butt->value(3); else { Msg(WARNING, "Something is wrong in your dynamic context definition"); return; @@ -689,7 +699,8 @@ void GUI::set_context(Context_Item *menu_asked, int flag){ Msg(STATUS2, menu[0].label+1); - if(m_module_butt->value() == 2){ // post-processing contexts + switch(m_module_butt->value()){ + case 3 : // post-processing contexts for(i = 0 ; i < List_Nbr(Post_ViewList) ; i++) { if(i == NB_BUTT_MAX) break; nb++ ; @@ -705,8 +716,10 @@ void GUI::set_context(Context_Item *menu_asked, int flag){ m_toggle_butt[i]->hide(); m_popup_butt[i]->hide(); } - } - else{ // geometry and mesh contexts + break; + case 2 : // solver contexts + break; + default : // geometry or mesh contexts for(i=0 ; i < NB_BUTT_MAX ; i++){ m_toggle_butt[i]->hide(); m_popup_butt[i]->hide(); @@ -725,6 +738,7 @@ void GUI::set_context(Context_Item *menu_asked, int flag){ m_popup_butt[i]->hide(); m_push_butt[i]->hide(); } + break ; } set_menu_size(nb); diff --git a/Fltk/GUI.h b/Fltk/GUI.h index cebdcdde88e32bafbb1f54a9cdcbbe64f28d69d7..fb9e80959638a4689589d51d7d01b0f390f2dc39 100644 --- a/Fltk/GUI.h +++ b/Fltk/GUI.h @@ -59,6 +59,7 @@ extern Context_Item menu_geometry_physical_add[]; extern Context_Item menu_mesh[]; extern Context_Item menu_mesh_define[]; extern Context_Item menu_mesh_define_transfinite[]; +extern Context_Item menu_solver[]; extern Context_Item menu_post[]; // Forward Declarations diff --git a/Parser/OpenFile.cpp b/Parser/OpenFile.cpp index 902b6d4ad85e645e85c35f2d6e33e821d637b55e..f66dc782e8261d00d3a7b373f734f7a4fb12a912 100644 --- a/Parser/OpenFile.cpp +++ b/Parser/OpenFile.cpp @@ -1,4 +1,4 @@ -// $Id: OpenFile.cpp,v 1.13 2001-04-26 17:58:00 remacle Exp $ +// $Id: OpenFile.cpp,v 1.14 2001-05-01 18:58:24 geuzaine Exp $ #include "Gmsh.h" #include "Const.h" #include "Context.h" @@ -103,7 +103,7 @@ void OpenProblem(char *name){ strcpy(ext,name+(strlen(name)-4)); if(!strcmp(ext,".geo") || !strcmp(ext,".GEO") || !strcmp(ext,".msh") || !strcmp(ext,".MSH") || - !strcmp(ext,".stl") || !strcmp(ext,".MSH") || + !strcmp(ext,".stl") || !strcmp(ext,".STL") || !strcmp(ext,".sms") || !strcmp(ext,".SMS") || !strcmp(ext,".pos") || !strcmp(ext,".POS")){ CTX.basefilename[strlen(name)-4] = '\0'; diff --git a/doc/CONTRIBUTORS b/doc/CONTRIBUTORS index a69c0a0e689aacfab45d14986256e5a3c2a19e17..894ffa39ebbeba9e35f981d5c8a2b5d3cb850b0f 100644 --- a/doc/CONTRIBUTORS +++ b/doc/CONTRIBUTORS @@ -1,4 +1,4 @@ -$Id: CONTRIBUTORS,v 1.4 2001-04-25 20:42:39 geuzaine Exp $ +$Id: CONTRIBUTORS,v 1.5 2001-05-01 18:58:24 geuzaine Exp $ Gmsh is copyright (c) 1997-2001 by @@ -7,6 +7,7 @@ Gmsh is copyright (c) 1997-2001 by Parts of the code have been contributed by + Patrick Dular <patrick.dular@ulg.ac.be> Marc Umé <Marc.Ume@digitalgraphics.be> Special thanks to the following folks who have greatly contributed by @@ -19,7 +20,6 @@ will be added to the list! Éric Bechet <eric.bechet@epost.de> David Colignon <david.colignon@ulg.ac.be> - Patrick Dular <patrick.dular@ulg.ac.be> Philippe Geuzaine <geuzaine@gnat.colorado.edu> Johan Gyselinck <johan.gyselinck@ulg.ac.be> François Henrotte <fhenrott@esat.kuleuven.ac.be>