diff options
| author | Albrecht Schlosser <albrechts.fltk@online.de> | 2021-03-20 21:39:28 +0100 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2021-03-21 00:42:28 +0100 |
| commit | 41266df7ae51f179f4a80f67a2eba896ba1fd7b2 (patch) | |
| tree | 52103dcc63cd91c58b6f599ca7595b254549b3cb /test | |
| parent | bd52db0b952d35ce793153e4a0c0b25f102a4395 (diff) | |
Remove unnecessary system includes from public headers
Add includes of system headers in the implementation files
where necessary.
Diffstat (limited to 'test')
| -rw-r--r-- | test/file_chooser.cxx | 10 | ||||
| -rw-r--r-- | test/table.cxx | 10 | ||||
| -rw-r--r-- | test/unittests.cxx | 7 |
3 files changed, 14 insertions, 13 deletions
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 <stdio.h> #include <FL/Fl_File_Chooser.H> #include <FL/Fl_File_Icon.H> #include <FL/Fl_Shared_Image.H> @@ -38,7 +37,10 @@ #include <FL/Fl_Light_Button.H> #include <FL/Fl_Double_Window.H> #include <FL/Fl_Simple_Terminal.H> + +#include <stdio.h> #include <string.h> +#include <stdlib.h> // exit() #include <locale.h> // 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 <stdio.h> -#include <string.h> -#ifdef _WIN32 -#include <stdlib.h> // atoi -#endif /* _WIN32 */ - #include <FL/Fl.H> #include <FL/Fl_Window.H> #include <FL/Fl_Input.H> @@ -18,6 +12,10 @@ #include <FL/Fl_Table_Row.H> #include <FL/Fl_Simple_Terminal.H> +#include <stdio.h> +#include <string.h> +#include <stdlib.h> // 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 <FL/Fl_Help_View.H> #include <FL/Fl_Group.H> #include <FL/Fl_Box.H> -#include <FL/fl_draw.H> // fl_text_extents() -#include <FL/fl_string.h> // fl_strdup() +#include <FL/fl_draw.H> // fl_text_extents() +#include <FL/fl_string.h> // fl_strdup() +#include <stdlib.h> // malloc, free // WINDOW/WIDGET SIZES #define MAINWIN_W 700 // main window w() |
