summaryrefslogtreecommitdiff
path: root/FL
diff options
context:
space:
mode:
authorAlbrecht Schlosser <albrechts.fltk@online.de>2023-04-13 20:14:36 +0200
committerAlbrecht Schlosser <albrechts.fltk@online.de>2023-04-13 20:14:36 +0200
commit7b2c770ef7385276bf4884ffe308a6c79a8046ef (patch)
tree8807828cb2a1f6fdeee5ac86032918b5055c146f /FL
parent9d380f24bd4b13731c702047a2f212a287c993db (diff)
Fix trailing comma in enums of public headers
Compiler warning: comma at end of enumerator list [-Wpedantic] Note 1: I decided to fix these warnings although trailing commas in enums are allowed at least since C++11. Note 2: I fixed only public headers because these headers may be compiled in user code. To do: check internal headers.
Diffstat (limited to 'FL')
-rw-r--r--FL/Enumerations.H2
-rw-r--r--FL/Fl_Preferences.H4
-rw-r--r--FL/Fl_Table.H2
-rw-r--r--FL/Fl_Tabs.H2
-rw-r--r--FL/Fl_Text_Display.H2
-rw-r--r--FL/Fl_Tree_Item_Array.H2
-rw-r--r--FL/Fl_Tree_Prefs.H2
-rw-r--r--FL/fl_casts.H5
-rw-r--r--FL/fl_message.H7
-rw-r--r--FL/gl2opengl.h5
-rw-r--r--FL/glut.H10
11 files changed, 29 insertions, 14 deletions
diff --git a/FL/Enumerations.H b/FL/Enumerations.H
index 906aca9f3..914fc6a56 100644
--- a/FL/Enumerations.H
+++ b/FL/Enumerations.H
@@ -455,7 +455,7 @@ enum Fl_Callback_Reason {
FL_REASON_CHANGED, ///< the value of the widget was modified
FL_REASON_GOT_FOCUS, ///< a widget received focus
FL_REASON_LOST_FOCUS, ///< a widget lost focus
- FL_REASON_RELEASED, ///< the mouse button was released
+ FL_REASON_RELEASED ///< the mouse button was released
};
/**@}*/ // group: Callback Reasons
diff --git a/FL/Fl_Preferences.H b/FL/Fl_Preferences.H
index 7112ea42b..a74be23eb 100644
--- a/FL/Fl_Preferences.H
+++ b/FL/Fl_Preferences.H
@@ -1,7 +1,7 @@
//
// Preferences implementation for the Fast Light Tool Kit (FLTK).
//
-// Copyright 2002-2022 by Matthias Melcher.
+// Copyright 2002-2023 by Matthias Melcher.
//
// 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
@@ -137,7 +137,7 @@ public:
CORE_SYSTEM_L = CORE | SYSTEM_L, ///< Same as CORE | SYSTEM | C_LOCALE
CORE_USER_L = CORE | USER_L, ///< Same as CORE | USER | C_LOCALE
CORE_SYSTEM = CORE | SYSTEM, ///< Deprecated, same as CORE | SYSTEM. Use CORE_SYSTEM_L instead.
- CORE_USER = CORE | USER, ///< Deprecated, same as CORE | USER. Use CORE_USER_L instead.
+ CORE_USER = CORE | USER ///< Deprecated, same as CORE | USER. Use CORE_USER_L instead.
};
/**
diff --git a/FL/Fl_Table.H b/FL/Fl_Table.H
index d6b4c4738..9f31fa020 100644
--- a/FL/Fl_Table.H
+++ b/FL/Fl_Table.H
@@ -151,7 +151,7 @@ private:
int _selecting;
int _scrollbar_size;
enum {
- TABCELLNAV = 1<<0, ///> tab cell navigation flag
+ TABCELLNAV = 1<<0 ///> tab cell navigation flag
};
unsigned int flags_;
diff --git a/FL/Fl_Tabs.H b/FL/Fl_Tabs.H
index 334be5773..278e1a437 100644
--- a/FL/Fl_Tabs.H
+++ b/FL/Fl_Tabs.H
@@ -303,7 +303,7 @@ public:
OVERFLOW_COMPRESS = 0,
OVERFLOW_CLIP,
OVERFLOW_PULLDOWN,
- OVERFLOW_DRAG,
+ OVERFLOW_DRAG
};
void handle_overflow(int ov);
diff --git a/FL/Fl_Text_Display.H b/FL/Fl_Text_Display.H
index 6e687a60b..881671d40 100644
--- a/FL/Fl_Text_Display.H
+++ b/FL/Fl_Text_Display.H
@@ -161,7 +161,7 @@ public:
ATTR_GRAMMAR = 0x0008, ///< grammar suggestion (blue dotted underline)
ATTR_SPELLING = 0x000C, ///< spelling suggestion (red dotted underline)
ATTR_STRIKE_THROUGH = 0x0010, ///< line through the middle of the text
- ATTR_LINES_MASK = 0x001C, ///< the mask for all underline and strike through types
+ ATTR_LINES_MASK = 0x001C ///< the mask for all underline and strike through types
};
Fl_Text_Display(int X, int Y, int W, int H, const char *l = 0);
diff --git a/FL/Fl_Tree_Item_Array.H b/FL/Fl_Tree_Item_Array.H
index dc4da5ff3..78e71bb5b 100644
--- a/FL/Fl_Tree_Item_Array.H
+++ b/FL/Fl_Tree_Item_Array.H
@@ -48,7 +48,7 @@ class FL_EXPORT Fl_Tree_Item_Array {
int _size; // #items *allocated* for array
int _chunksize; // #items to enlarge mem allocation
enum {
- MANAGE_ITEM = 1, ///> manage the Fl_Tree_Item's internals (internal use only)
+ MANAGE_ITEM = 1 ///> manage the Fl_Tree_Item's internals (internal use only)
};
char _flags; // flags to control behavior
void enlarge(int count);
diff --git a/FL/Fl_Tree_Prefs.H b/FL/Fl_Tree_Prefs.H
index e6e010734..addae10e7 100644
--- a/FL/Fl_Tree_Prefs.H
+++ b/FL/Fl_Tree_Prefs.H
@@ -77,7 +77,7 @@ enum Fl_Tree_Select {
///
enum Fl_Tree_Item_Reselect_Mode {
FL_TREE_SELECTABLE_ONCE=0, ///< Item can only be selected once (default)
- FL_TREE_SELECTABLE_ALWAYS, ///< Enables FL_TREE_REASON_RESELECTED events for callbacks
+ FL_TREE_SELECTABLE_ALWAYS ///< Enables FL_TREE_REASON_RESELECTED events for callbacks
};
/// \enum Fl_Tree_Item_Draw_Mode
diff --git a/FL/fl_casts.H b/FL/fl_casts.H
index 1d0d881cd..cb9a708db 100644
--- a/FL/fl_casts.H
+++ b/FL/fl_casts.H
@@ -15,6 +15,9 @@
// https://www.fltk.org/bugs.php
//
+#ifndef _FL_fl_casts_H_
+#define _FL_fl_casts_H_
+
#include <FL/platform_types.h>
inline char fl_char(void *v) { return (char)(fl_intptr_t)v; }
@@ -32,3 +35,5 @@ inline void *fl_voidptr(int v) { return (void *)(fl_intptr_t)v; }
inline void *fl_voidptr(unsigned int v) { return (void *)(fl_uintptr_t)v; }
inline void *fl_voidptr(long v) { return (void *)(fl_intptr_t)v; }
inline void *fl_voidptr(unsigned long v) { return (void *)(fl_uintptr_t)v; }
+
+#endif /* _FL_fl_casts_H_ */
diff --git a/FL/fl_message.H b/FL/fl_message.H
index 5932b76b8..50f2ef991 100644
--- a/FL/fl_message.H
+++ b/FL/fl_message.H
@@ -1,7 +1,7 @@
//
// Standard message header file for the Fast Light Tool Kit (FLTK).
//
-// Copyright 1998-2010 by Bill Spitzak and others.
+// Copyright 1998-2023 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,4 +14,9 @@
// https://www.fltk.org/bugs.php
//
+#ifndef _FL_fl_message_H_
+#define _FL_fl_message_H_
+
#include "fl_ask.H"
+
+#endif
diff --git a/FL/gl2opengl.h b/FL/gl2opengl.h
index 5ba1fef20..a22fd3df3 100644
--- a/FL/gl2opengl.h
+++ b/FL/gl2opengl.h
@@ -6,6 +6,9 @@
*/
+#ifndef _FL_gl2opengl_h_
+#define _FL_gl2opengl_h_
+
#include <FL/gl.h>
#include "gl_draw.H"
@@ -33,3 +36,5 @@ inline void recti(int x,int y,int r,int t) {gl_rect(x,y,r-x,t-y);}
inline void rectfi(int x,int y,int r,int t) {glRecti(x,y,r+1,t+1);}
inline void rects(int x,int y,int r,int t) {gl_rect(x,y,r-x,t-y);}
inline void rectfs(int x,int y,int r,int t) {glRects(x,y,r+1,t+1);}
+
+#endif /* _FL_gl2opengl_h_ */
diff --git a/FL/glut.H b/FL/glut.H
index f83231c3a..2d4a196c2 100644
--- a/FL/glut.H
+++ b/FL/glut.H
@@ -1,7 +1,7 @@
//
// GLUT emulation header file for the Fast Light Tool Kit (FLTK).
//
-// Copyright 1998-2015 by Bill Spitzak and others.
+// Copyright 1998-2023 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
@@ -26,8 +26,8 @@
// Commented out lines indicate parts of GLUT that are not emulated.
-#ifndef Fl_glut_H
-# define Fl_glut_H
+#ifndef _FL_glut_H_
+# define _FL_glut_H_
# include "gl.h"
@@ -320,7 +320,7 @@ enum {
//GLUT_WINDOW_CURSOR,
//GLUT_SCREEN_WIDTH_MM,
//GLUT_SCREEN_HEIGHT_MM,
- GLUT_ELAPSED_TIME,
+ GLUT_ELAPSED_TIME
};
# define GLUT_WINDOW_STENCIL_SIZE GL_STENCIL_BITS
@@ -472,4 +472,4 @@ FL_EXPORT void glutSolidTetrahedron();
FL_EXPORT void glutWireIcosahedron();
FL_EXPORT void glutSolidIcosahedron();
-#endif // !Fl_glut_H
+#endif // !_FL_glut_H_