From 41266df7ae51f179f4a80f67a2eba896ba1fd7b2 Mon Sep 17 00:00:00 2001 From: Albrecht Schlosser Date: Sat, 20 Mar 2021 21:39:28 +0100 Subject: [PATCH] Remove unnecessary system includes from public headers Add includes of system headers in the implementation files where necessary. --- FL/Fl.H | 1 + FL/Fl_Device.H | 3 +-- FL/Fl_File_Chooser.H | 5 +---- FL/Fl_Graphics_Driver.H | 1 - FL/Fl_Help_Dialog.H | 2 +- FL/Fl_Image.H | 1 - FL/Fl_Input_Choice.H | 9 +-------- FL/Fl_Text_Buffer.H | 4 ++-- FL/Fl_Window.H | 1 - FL/fl_utf8.h | 4 +--- examples/OpenGL3-glut-test.cxx | 6 +++--- fluid/ExternalCodeEditor_WIN32.cxx | 5 +++-- fluid/Fl_Type.h | 1 + fluid/Fluid_Image.cxx | 5 +++-- src/Fl_File_Chooser.cxx | 2 +- src/Fl_File_Chooser.fl | 11 ++++------- src/Fl_Gl_Choice.cxx | 13 +++++++------ src/Fl_Graphics_Driver.cxx | 3 ++- src/Fl_Help_Dialog.cxx | 2 +- src/Fl_Help_Dialog.fl | 2 +- src/Fl_Image_Surface.cxx | 4 +++- src/Fl_Table_Row.cxx | 1 + src/Fl_Tabs.cxx | 6 ++++-- src/Fl_Tile.cxx | 1 + src/drivers/GDI/Fl_GDI_Graphics_Driver.H | 4 ++-- src/drivers/SVG/Fl_SVG_File_Surface.cxx | 1 + src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx | 1 + .../Xlib/Fl_Xlib_Graphics_Driver_line_style.cxx | 4 ++-- src/fl_ask.cxx | 12 ++++++------ src/fl_draw.cxx | 2 +- src/gl_draw.cxx | 3 ++- src/makedepend | 1 + test/file_chooser.cxx | 10 ++++++---- test/table.cxx | 10 ++++------ test/unittests.cxx | 7 ++++--- 35 files changed, 73 insertions(+), 75 deletions(-) diff --git a/FL/Fl.H b/FL/Fl.H index dfa9c5748..1706cc2d5 100644 --- a/FL/Fl.H +++ b/FL/Fl.H @@ -42,6 +42,7 @@ # undef BSD # endif +#include // FIXME: Fl::is_scheme(): strcmp needs string.h class Fl_Widget; class Fl_Window; diff --git a/FL/Fl_Device.H b/FL/Fl_Device.H index f7ec44052..9615bdc44 100644 --- a/FL/Fl_Device.H +++ b/FL/Fl_Device.H @@ -2,7 +2,7 @@ // Definition of classes Fl_Surface_Device, Fl_Display_Device // for the Fast Light Tool Kit (FLTK). // -// Copyright 2010-2017 by Bill Spitzak and others. +// Copyright 2010-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -24,7 +24,6 @@ #include #include -#include class Fl_Graphics_Driver; class Fl_RGB_Image; diff --git a/FL/Fl_File_Chooser.H b/FL/Fl_File_Chooser.H index 341b8e683..5935edc28 100644 --- a/FL/Fl_File_Chooser.H +++ b/FL/Fl_File_Chooser.H @@ -1,7 +1,7 @@ // // Fl_File_Chooser dialog for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2015 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -27,9 +27,6 @@ #define Fl_File_Chooser_H #include #include -#include -#include -#include #include #include #include diff --git a/FL/Fl_Graphics_Driver.H b/FL/Fl_Graphics_Driver.H index 974f1be3c..9d2b85f26 100644 --- a/FL/Fl_Graphics_Driver.H +++ b/FL/Fl_Graphics_Driver.H @@ -33,7 +33,6 @@ #include #include #include -#include class Fl_Graphics_Driver; class Fl_Font_Descriptor; diff --git a/FL/Fl_Help_Dialog.H b/FL/Fl_Help_Dialog.H index ef5f31028..ed19ca2a2 100644 --- a/FL/Fl_Help_Dialog.H +++ b/FL/Fl_Help_Dialog.H @@ -1,7 +1,7 @@ // // Fl_Help_Dialog dialog for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2015 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this diff --git a/FL/Fl_Image.H b/FL/Fl_Image.H index daac00165..f39e0eaeb 100644 --- a/FL/Fl_Image.H +++ b/FL/Fl_Image.H @@ -21,7 +21,6 @@ #define Fl_Image_H #include "Enumerations.H" -#include #include "Fl_Widget.H" // for fl_uintptr_t class Fl_Widget; diff --git a/FL/Fl_Input_Choice.H b/FL/Fl_Input_Choice.H index 9f29ce968..71bc76ee0 100644 --- a/FL/Fl_Input_Choice.H +++ b/FL/Fl_Input_Choice.H @@ -5,8 +5,8 @@ // | input area || \/ | // |______________||____| // -// Copyright 1998-2017 by Bill Spitzak and others. // Copyright 2004 by Greg Ercolano. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -30,13 +30,6 @@ #include #include -// Leaving these two headers so builds don't break if user includes this -// header and uses items from fl_draw or string (but doesn't include in src). -// Note: this would ensure compatibility with FLTK 1.3.x. -// Shall we? Currently not! -// #include -// #include - /* A combination of the input widget and a menu button. diff --git a/FL/Fl_Text_Buffer.H b/FL/Fl_Text_Buffer.H index 473e61c77..a1d044f48 100644 --- a/FL/Fl_Text_Buffer.H +++ b/FL/Fl_Text_Buffer.H @@ -1,7 +1,7 @@ // // Header file for Fl_Text_Buffer class. // -// Copyright 2001-2017 by Bill Spitzak and others. +// Copyright 2001-2021 by Bill Spitzak and others. // Original code Copyright Mark Edel. Permission to distribute under // the LGPL for the FLTK library granted by Mark Edel. // @@ -22,7 +22,7 @@ #ifndef FL_TEXT_BUFFER_H #define FL_TEXT_BUFFER_H -#include /* va_start/end */ +#include /* va_list */ #undef ASSERT_UTF8 diff --git a/FL/Fl_Window.H b/FL/Fl_Window.H index 9c83d7b11..4ce65f3bc 100644 --- a/FL/Fl_Window.H +++ b/FL/Fl_Window.H @@ -23,7 +23,6 @@ #include #include #include -#include #define FL_WINDOW 0xF0 ///< window type id: all subclasses have type() >= this #define FL_DOUBLE_WINDOW 0xF1 ///< double window type id diff --git a/FL/fl_utf8.h b/FL/fl_utf8.h index 8cf26900a..315f24cf6 100644 --- a/FL/fl_utf8.h +++ b/FL/fl_utf8.h @@ -29,9 +29,7 @@ #include "Fl_Export.H" #include "fl_types.h" -#include -#include -#include +#include // FILE *fl_fopen() #ifdef __cplusplus extern "C" { diff --git a/examples/OpenGL3-glut-test.cxx b/examples/OpenGL3-glut-test.cxx index 81a22c211..75ff3b0d1 100644 --- a/examples/OpenGL3-glut-test.cxx +++ b/examples/OpenGL3-glut-test.cxx @@ -1,7 +1,7 @@ // // Tiny OpenGL v3 + glut demo program for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2015 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -14,7 +14,6 @@ // https://www.fltk.org/bugs.php // -#include #if defined(__APPLE__) # define GL_DO_NOT_WARN_IF_MULTI_GL_VERSION_HEADERS_INCLUDED 1 # include // defines OpenGL 3.0+ functions @@ -25,7 +24,8 @@ # include #endif #include - +#include +#include // Globals // Real programs don't use globals :-D diff --git a/fluid/ExternalCodeEditor_WIN32.cxx b/fluid/ExternalCodeEditor_WIN32.cxx index b05adc638..695578749 100644 --- a/fluid/ExternalCodeEditor_WIN32.cxx +++ b/fluid/ExternalCodeEditor_WIN32.cxx @@ -3,8 +3,6 @@ // // Note: This entire file Windows only. -#include // snprintf() - #include // Fl_Timeout_Handler.. #include // fl_alert() #include // fl_utf8fromwc() @@ -12,6 +10,9 @@ #include "ExternalCodeEditor_WIN32.h" +#include // snprintf() +#include + extern int G_debug; // defined in fluid.cxx // Static local data diff --git a/fluid/Fl_Type.h b/fluid/Fl_Type.h index 7b008f092..a6e030674 100644 --- a/fluid/Fl_Type.h +++ b/fluid/Fl_Type.h @@ -29,6 +29,7 @@ #include "Fluid_Image.h" #include #include +#include #ifdef _WIN32 #include "ExternalCodeEditor_WIN32.h" diff --git a/fluid/Fluid_Image.cxx b/fluid/Fluid_Image.cxx index 1f41a09fd..ba44175f3 100644 --- a/fluid/Fluid_Image.cxx +++ b/fluid/Fluid_Image.cxx @@ -16,6 +16,9 @@ #include #include +#include +#include +#include // fl_fopen() #include "Fl_Type.h" #include "Fluid_Image.h" #include "../src/flstring.h" @@ -23,8 +26,6 @@ #include #include #include -#include -#include extern void goto_source_dir(); // in fluid.cxx extern void leave_source_dir(); // in fluid.cxx diff --git a/src/Fl_File_Chooser.cxx b/src/Fl_File_Chooser.cxx index 22fadf57f..b2993633d 100644 --- a/src/Fl_File_Chooser.cxx +++ b/src/Fl_File_Chooser.cxx @@ -1,7 +1,7 @@ // // Fl_File_Chooser dialog for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2015 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this diff --git a/src/Fl_File_Chooser.fl b/src/Fl_File_Chooser.fl index 62009f89d..7bffa6411 100644 --- a/src/Fl_File_Chooser.fl +++ b/src/Fl_File_Chooser.fl @@ -5,7 +5,7 @@ code_name {.cxx} comment {// // Fl_File_Chooser dialog for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2015 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -77,12 +77,9 @@ class FL_EXPORT Fl_File_Chooser {open callback {fileName->value(""); fileList->deselect(); Fl::remove_timeout((Fl_Timeout_Handler)previewCB, this); -window->hide();} open +window->hide();} open selected private xywh {1171 438 490 380} type Double hide resizable - code0 {if (title) window->label(title);} - code1 {\#include } - code2 {\#include } - code3 {\#include } modal + code0 {if (title) window->label(title);} modal } { Fl_Group {} {open private xywh {10 10 470 25} @@ -116,7 +113,7 @@ window->hide();} open code0 {\#include } } Fl_Box errorBox { - label {dynamic error display} selected + label {dynamic error display} private xywh {10 45 295 225} box DOWN_BOX color 7 labelsize 18 labelcolor 1 align 149 hide } Fl_Box previewBox { diff --git a/src/Fl_Gl_Choice.cxx b/src/Fl_Gl_Choice.cxx index 6b718fcfd..f0ddda652 100644 --- a/src/Fl_Gl_Choice.cxx +++ b/src/Fl_Gl_Choice.cxx @@ -1,7 +1,7 @@ // // OpenGL visual selection code for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2018 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -22,11 +22,12 @@ \addtogroup DriverDeveloper \{ */ -# include -# include "Fl_Gl_Choice.H" -# include -# include "Fl_Gl_Window_Driver.H" -# include +#include +#include "Fl_Gl_Choice.H" +#include +#include "Fl_Gl_Window_Driver.H" +#include +#include GLContext *Fl_Gl_Window_Driver::context_list = 0; int Fl_Gl_Window_Driver::nContext = 0; diff --git a/src/Fl_Graphics_Driver.cxx b/src/Fl_Graphics_Driver.cxx index 5386d5290..3ac4d3154 100644 --- a/src/Fl_Graphics_Driver.cxx +++ b/src/Fl_Graphics_Driver.cxx @@ -1,7 +1,7 @@ // // Fl_Graphics_Driver class for the Fast Light Tool Kit (FLTK). // -// Copyright 2010-2020 by Bill Spitzak and others. +// Copyright 2010-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -29,6 +29,7 @@ #include #include #include +#include FL_EXPORT Fl_Graphics_Driver *fl_graphics_driver; // the current driver of graphics operations diff --git a/src/Fl_Help_Dialog.cxx b/src/Fl_Help_Dialog.cxx index 580812818..54bbee1c2 100644 --- a/src/Fl_Help_Dialog.cxx +++ b/src/Fl_Help_Dialog.cxx @@ -1,7 +1,7 @@ // // Fl_Help_Dialog dialog for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2015 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this diff --git a/src/Fl_Help_Dialog.fl b/src/Fl_Help_Dialog.fl index 08ceef804..6aeb12e94 100644 --- a/src/Fl_Help_Dialog.fl +++ b/src/Fl_Help_Dialog.fl @@ -5,7 +5,7 @@ code_name {.cxx} comment {// // Fl_Help_Dialog dialog for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2015 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this diff --git a/src/Fl_Image_Surface.cxx b/src/Fl_Image_Surface.cxx index e273a4c2f..e2870e578 100644 --- a/src/Fl_Image_Surface.cxx +++ b/src/Fl_Image_Surface.cxx @@ -1,7 +1,7 @@ // // Draw-to-image code for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2017 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -18,6 +18,8 @@ #include // necessary for FL_EXPORT fl_*_offscreen() +#include // realloc() + /** Constructor with optional high resolution. \param w,h Width and height of the resulting image. The value of the \p high_res parameter controls whether \p w and \p h are interpreted as pixels or FLTK units. diff --git a/src/Fl_Table_Row.cxx b/src/Fl_Table_Row.cxx index 33a1e4dd4..29d77747e 100644 --- a/src/Fl_Table_Row.cxx +++ b/src/Fl_Table_Row.cxx @@ -25,6 +25,7 @@ #include #include #include +#include // for debugging... // #define DEBUG 1 diff --git a/src/Fl_Tabs.cxx b/src/Fl_Tabs.cxx index 17b73fdc9..4c83b6476 100644 --- a/src/Fl_Tabs.cxx +++ b/src/Fl_Tabs.cxx @@ -1,7 +1,7 @@ // // Tab widget for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2018 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -20,12 +20,14 @@ // Each child widget is a card, and its label() is printed on the card tab. // Clicking the tab makes that card visible. -#include #include #include #include #include +#include +#include + #define BORDER 2 #define EXTRASPACE 10 #define SELECTION_BORDER 5 diff --git a/src/Fl_Tile.cxx b/src/Fl_Tile.cxx index 997c6dd2d..9b42d5f69 100644 --- a/src/Fl_Tile.cxx +++ b/src/Fl_Tile.cxx @@ -85,6 +85,7 @@ #include #include #include +#include /** Drags the intersection at (\p oldx,\p oldy) to (\p newx,\p newy). diff --git a/src/drivers/GDI/Fl_GDI_Graphics_Driver.H b/src/drivers/GDI/Fl_GDI_Graphics_Driver.H index cf8ae3e98..9016e9f5a 100644 --- a/src/drivers/GDI/Fl_GDI_Graphics_Driver.H +++ b/src/drivers/GDI/Fl_GDI_Graphics_Driver.H @@ -2,7 +2,7 @@ // Definition of classes Fl_Graphics_Driver, Fl_Surface_Device, Fl_Display_Device // for the Fast Light Tool Kit (FLTK). // -// Copyright 2010-2018 by Bill Spitzak and others. +// Copyright 2010-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -25,7 +25,7 @@ #include #include - +#include /** \brief The Windows-specific graphics driver class. diff --git a/src/drivers/SVG/Fl_SVG_File_Surface.cxx b/src/drivers/SVG/Fl_SVG_File_Surface.cxx index 08727c842..371e618e1 100644 --- a/src/drivers/SVG/Fl_SVG_File_Surface.cxx +++ b/src/drivers/SVG/Fl_SVG_File_Surface.cxx @@ -29,6 +29,7 @@ #include #include #include +#include extern "C" { #if defined(HAVE_LIBPNG) diff --git a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx index 6401efa97..a96682554 100644 --- a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx +++ b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver.cxx @@ -22,6 +22,7 @@ #include #include +#include extern XIC fl_xim_ic; extern char fl_is_over_the_spot; diff --git a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_line_style.cxx b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_line_style.cxx index 1aaeceea1..17fbba7fa 100644 --- a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_line_style.cxx +++ b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_line_style.cxx @@ -1,7 +1,7 @@ // // Line style code for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2018 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -23,8 +23,8 @@ #include #include #include "../../flstring.h" - #include "Fl_Xlib_Graphics_Driver.H" +#include void Fl_Xlib_Graphics_Driver::line_style_unscaled(int style, int width, char* dashes) { diff --git a/src/fl_ask.cxx b/src/fl_ask.cxx index f711a9f1d..c9255f14e 100644 --- a/src/fl_ask.cxx +++ b/src/fl_ask.cxx @@ -1,7 +1,7 @@ // // Standard dialog functions for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2020 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -24,14 +24,10 @@ // mostly. In most cases it is easier to get a multi-line message // by putting newlines in the message. -#include -#include -#include "flstring.h" - #include #include - #include +#include "flstring.h" #include #include @@ -43,6 +39,10 @@ #include "Fl_Screen_Driver.H" #include +#include +#include +#include + static Fl_Window *message_form; static Fl_Box *message; static Fl_Box *icon; diff --git a/src/fl_draw.cxx b/src/fl_draw.cxx index 16906366d..ba33db96e 100644 --- a/src/fl_draw.cxx +++ b/src/fl_draw.cxx @@ -30,7 +30,7 @@ #include "flstring.h" #include #include - +#include char fl_draw_shortcut; // set by fl_labeltypes.cxx diff --git a/src/gl_draw.cxx b/src/gl_draw.cxx index 048510266..f802376cb 100644 --- a/src/gl_draw.cxx +++ b/src/gl_draw.cxx @@ -1,7 +1,7 @@ // // OpenGL text drawing support routines for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2018 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -42,6 +42,7 @@ #include #include // for gluUnProject() #include // for glutStrokeString() and glutStrokeLength() +#include #ifndef GL_TEXTURE_RECTANGLE_ARB # define GL_TEXTURE_RECTANGLE_ARB 0x84F5 diff --git a/src/makedepend b/src/makedepend index 7a511e043..ee601e022 100644 --- a/src/makedepend +++ b/src/makedepend @@ -1,5 +1,6 @@ # DO NOT DELETE THIS LINE -- make depend depends on it. +drivers/Cairo/Fl_Cairo_Graphics_Driver.o: ../config.h drivers/OpenGL/Fl_OpenGL_Display_Device.o: ../config.h drivers/OpenGL/Fl_OpenGL_Display_Device.o: ../FL/abi-version.h drivers/OpenGL/Fl_OpenGL_Display_Device.o: ../FL/Enumerations.H diff --git a/test/file_chooser.cxx b/test/file_chooser.cxx index abd5a081e..b705f052e 100644 --- a/test/file_chooser.cxx +++ b/test/file_chooser.cxx @@ -2,7 +2,7 @@ // File chooser test program. // // Copyright 1999-2010 by Michael Sweet. -// Copyright 2011-2019 by Bill Spitzak and others. +// Copyright 2011-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -30,7 +30,6 @@ // Include necessary headers... // -#include #include #include #include @@ -38,7 +37,10 @@ #include #include #include + +#include #include +#include // exit() #include // setlocale().. #define TERMINAL_HEIGHT 120 @@ -300,7 +302,7 @@ pdf_check(const char *name, // I - Name of file "-sstdout=\"%%stderr\" -sOUTPUTFILE=\'%s\' " "-dFirstPage=1 -dLastPage=1 \'%s\' 2>/dev/null", preview, name); - if (system(command)) return 0; + if (fl_system(command)) return 0; return new Fl_PNM_Image(preview); } @@ -363,7 +365,7 @@ ps_check(const char *name, // I - Name of file "-sstdout=\"%%stderr\" -sOUTPUTFILE=\'%s\' \'%s\' 2>/dev/null", preview, outname); - if (system(command)) return 0; + if (fl_system(command)) return 0; return new Fl_PNM_Image(preview); } diff --git a/test/table.cxx b/test/table.cxx index 2e5f0f639..1a540ea4f 100644 --- a/test/table.cxx +++ b/test/table.cxx @@ -2,12 +2,6 @@ // exercisetablerow -- Exercise all aspects of the Fl_Table_Row widget // -#include -#include -#ifdef _WIN32 -#include // atoi -#endif /* _WIN32 */ - #include #include #include @@ -18,6 +12,10 @@ #include #include +#include +#include +#include // atoi + #define TERMINAL_HEIGHT 120 // Globals diff --git a/test/unittests.cxx b/test/unittests.cxx index ca04aac62..22e6220a2 100644 --- a/test/unittests.cxx +++ b/test/unittests.cxx @@ -1,7 +1,7 @@ // // Unit tests for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2017 by Bill Spitzak and others. +// Copyright 1998-2021 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -27,8 +27,9 @@ #include #include #include -#include // fl_text_extents() -#include // fl_strdup() +#include // fl_text_extents() +#include // fl_strdup() +#include // malloc, free // WINDOW/WIDGET SIZES #define MAINWIN_W 700 // main window w()