From 6efeffe8260fa6e06add5491ebd111386df1b86c Mon Sep 17 00:00:00 2001
From: Christophe Geuzaine <cgeuzaine@ulg.ac.be>
Date: Fri, 12 Apr 2002 18:43:23 +0000
Subject: [PATCH] small changes for fltk2

---
 Fltk/Callbacks.cpp | 5 +++--
 Fltk/GUI.cpp       | 6 ++++--
 Makefile           | 3 +--
 Plugin/Plugin.cpp  | 4 ++--
 4 files changed, 10 insertions(+), 8 deletions(-)

diff --git a/Fltk/Callbacks.cpp b/Fltk/Callbacks.cpp
index 1a4faa1db0..4bffbba74a 100644
--- a/Fltk/Callbacks.cpp
+++ b/Fltk/Callbacks.cpp
@@ -1,4 +1,4 @@
-// $Id: Callbacks.cpp,v 1.114 2002-04-06 00:59:48 geuzaine Exp $
+// $Id: Callbacks.cpp,v 1.115 2002-04-12 18:43:23 geuzaine Exp $
 
 #include <sys/types.h>
 #include <signal.h>
@@ -32,7 +32,7 @@ extern Context_T  CTX;
 
 // File chooser (re)definitions
 
-#if (FL_MAJOR_VERSION == 1) && (FL_MINOR_VERSION == 0)
+#if (FL_MAJOR_VERSION == 1 || FL_MAJOR_VERSION == 2) && (FL_MINOR_VERSION == 0)
 
 #include <FL/fl_file_chooser.H>
 
@@ -51,6 +51,7 @@ char* file_chooser_get_name(int num){
 #else
 
 #include <FL/filename.H>
+
 #include <FL/Fl_File_Chooser.H>
 
 static Fl_File_Chooser *fc = NULL;
diff --git a/Fltk/GUI.cpp b/Fltk/GUI.cpp
index 986bcaba4f..97c5665c0d 100644
--- a/Fltk/GUI.cpp
+++ b/Fltk/GUI.cpp
@@ -1,4 +1,4 @@
-// $Id: GUI.cpp,v 1.162 2002-04-06 00:59:48 geuzaine Exp $
+// $Id: GUI.cpp,v 1.163 2002-04-12 18:43:23 geuzaine Exp $
 
 // To make the interface as visually consistent as possible, please:
 // - use the IW, BB, BH, BW and WB values
@@ -565,10 +565,12 @@ GUI::GUI(int argc, char **argv) {
   Fl::add_handler(SetGlobalShortcut);
 
   // set default font size
+#if !((FL_MAJOR_VERSION == 2) && (FL_MINOR_VERSION == 0))
   FL_NORMAL_SIZE = CTX.fontsize;
+#endif
 
   // handle themes and tooltip font size
-#if !((FL_MAJOR_VERSION == 1) && (FL_MINOR_VERSION == 0))
+#if !((FL_MAJOR_VERSION == 1 || FL_MAJOR_VERSION == 2) && (FL_MINOR_VERSION == 0))
   if(strlen(CTX.theme)) Fl::scheme(CTX.theme);
   Fl_Tooltip::size(CTX.fontsize);
 #endif
diff --git a/Makefile b/Makefile
index e1b9bcfbcd..eb7a87baed 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,4 @@
-# $Id: Makefile,v 1.194 2002-04-10 01:59:05 geuzaine Exp $
+# $Id: Makefile,v 1.195 2002-04-12 18:43:23 geuzaine Exp $
 
 GMSH_MAJOR_VERSION = 1
 GMSH_MINOR_VERSION = 34
@@ -306,7 +306,6 @@ link-fltk2:
 	$(CXX) -o $(GMSH_BIN_DIR)/gmsh $(GMSH_FLTK_LIB)\
                  $(HOME)/SOURCES/fltk-2.0/lib/libfltk_gl.so.2\
                  $(OPENGL_LIB) \
-                 $(HOME)/SOURCES/fltk-2.0/lib/libfltk_forms.so.2 \
                  $(HOME)/SOURCES/fltk-2.0/lib/libfltk.so.2 \
                  -L/usr/X11R6/lib $(X11_LIB) -lm
 fltk2: compile-fltk2 link-fltk2
diff --git a/Plugin/Plugin.cpp b/Plugin/Plugin.cpp
index 2b7945c35a..7fdb2e78a0 100644
--- a/Plugin/Plugin.cpp
+++ b/Plugin/Plugin.cpp
@@ -1,4 +1,4 @@
-// $Id: Plugin.cpp,v 1.24 2002-03-31 00:50:39 geuzaine Exp $
+// $Id: Plugin.cpp,v 1.25 2002-04-12 18:43:23 geuzaine Exp $
 
 #include <map>
 #ifndef _NODLL
@@ -127,7 +127,7 @@ void GMSH_PluginManager::RegisterDefaultPlugins(){
 #ifdef _FLTK
   char *homeplugins = getenv ("GMSHPLUGINSHOME");
   if(!homeplugins) return;
-#if (FL_MAJOR_VERSION == 1) && (FL_MINOR_VERSION == 0)
+#if (FL_MAJOR_VERSION == 1 || FL_MAJOR_VERSION == 2) && (FL_MINOR_VERSION == 0)
   int nbFiles = filename_list(homeplugins,&list);
 #else
   int nbFiles = fl_filename_list(homeplugins,&list);
-- 
GitLab