From 3c4fccec8be101a99d2cd292334a68f6c2937415 Mon Sep 17 00:00:00 2001 From: Christophe Geuzaine <cgeuzaine@ulg.ac.be> Date: Tue, 29 Jan 2013 15:52:16 +0000 Subject: [PATCH] tweak --- Fltk/helpWindow.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Fltk/helpWindow.cpp b/Fltk/helpWindow.cpp index 00cb3ece95..2b730ac028 100644 --- a/Fltk/helpWindow.cpp +++ b/Fltk/helpWindow.cpp @@ -41,7 +41,6 @@ static void numberOrStringChooser(const std::string &category, int index, Fl_Double_Window *win = new Fl_Double_Window(width, height, "Set Value"); win->border(0); win->set_modal(); - //win->hotspot(win); win->position(Fl::event_x_root() - BB, Fl::event_y_root() - BH / 2); Fl_Value_Input *number = 0; Fl_Input *string = 0; @@ -68,6 +67,7 @@ static void numberOrStringChooser(const std::string &category, int index, if (!o) break; if (o == win) { done = true; + break; } if(o == set){ if(num){ @@ -81,6 +81,7 @@ static void numberOrStringChooser(const std::string &category, int index, name.c_str(), vals); } done = true; + break; } if(o == reset){ if(num) @@ -90,6 +91,7 @@ static void numberOrStringChooser(const std::string &category, int index, StringOption(GMSH_SET_DEFAULT|GMSH_GUI, category.c_str(), index, name.c_str(), vals); done = true; + break; } } } @@ -104,7 +106,7 @@ static void colorChooser(const std::string &category, int index, uchar r = CTX::instance()->unpackRed(col); uchar g = CTX::instance()->unpackGreen(col); uchar b = CTX::instance()->unpackBlue(col); - if(fl_color_chooser("Color Chooser", r, g, b)){ + if(fl_color_chooser("Color Chooser", r, g, b, 1)){ col = CTX::instance()->packColor(r, g, b, 255); ColorOption(GMSH_SET|GMSH_GUI, category.c_str(), index, name.c_str(), col); } @@ -310,7 +312,6 @@ helpWindow::helpWindow() basic->end(); } - { int width = 40 * FL_NORMAL_SIZE; int height = 18 * BH; -- GitLab