summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJed Barber <jjbarber@y7mail.com>2017-05-14 14:04:45 +1000
committerJed Barber <jjbarber@y7mail.com>2017-05-14 14:04:45 +1000
commit8262e35fb43d8ab0e1d82d966e3d6bb415a7ade7 (patch)
tree7a69e7f18b992641de7de9cad98dbb44342c7e3e /src
parentf3638a598d55629bf130c648416ca75f5edae1f1 (diff)
Moved hook pointer typedefs to separate file
Diffstat (limited to 'src')
-rw-r--r--src/c_fl_box.cpp11
-rw-r--r--src/c_fl_button.cpp11
-rw-r--r--src/c_fl_check_button.cpp11
-rw-r--r--src/c_fl_double_window.cpp11
-rw-r--r--src/c_fl_file_input.cpp11
-rw-r--r--src/c_fl_float_input.cpp11
-rw-r--r--src/c_fl_group.cpp11
-rw-r--r--src/c_fl_input.cpp11
-rw-r--r--src/c_fl_int_input.cpp11
-rw-r--r--src/c_fl_light_button.cpp11
-rw-r--r--src/c_fl_menu.cpp11
-rw-r--r--src/c_fl_menu_bar.cpp11
-rw-r--r--src/c_fl_menu_button.cpp11
-rw-r--r--src/c_fl_menu_window.cpp11
-rw-r--r--src/c_fl_multiline_input.cpp11
-rw-r--r--src/c_fl_multiline_output.cpp11
-rw-r--r--src/c_fl_output.cpp11
-rw-r--r--src/c_fl_radio_button.cpp11
-rw-r--r--src/c_fl_radio_light_button.cpp11
-rw-r--r--src/c_fl_radio_round_button.cpp11
-rw-r--r--src/c_fl_repeat_button.cpp11
-rw-r--r--src/c_fl_return_button.cpp11
-rw-r--r--src/c_fl_round_button.cpp11
-rw-r--r--src/c_fl_secret_input.cpp11
-rw-r--r--src/c_fl_single_window.cpp11
-rw-r--r--src/c_fl_text_display.cpp11
-rw-r--r--src/c_fl_text_editor.cpp11
-rw-r--r--src/c_fl_toggle_button.cpp11
-rw-r--r--src/c_fl_type.h16
-rw-r--r--src/c_fl_widget.cpp11
-rw-r--r--src/c_fl_window.cpp11
31 files changed, 46 insertions, 300 deletions
diff --git a/src/c_fl_box.cpp b/src/c_fl_box.cpp
index 40e527d..7e2cc22 100644
--- a/src/c_fl_box.cpp
+++ b/src/c_fl_box.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Box.H>
#include "c_fl_box.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_button.cpp b/src/c_fl_button.cpp
index 725a0bc..d164fb0 100644
--- a/src/c_fl_button.cpp
+++ b/src/c_fl_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Button.H>
#include "c_fl_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_check_button.cpp b/src/c_fl_check_button.cpp
index 23e81ed..2b5bdf1 100644
--- a/src/c_fl_check_button.cpp
+++ b/src/c_fl_check_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Check_Button.H>
#include "c_fl_check_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_double_window.cpp b/src/c_fl_double_window.cpp
index b49010e..298c489 100644
--- a/src/c_fl_double_window.cpp
+++ b/src/c_fl_double_window.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Double_Window.H>
#include "c_fl_double_window.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_file_input.cpp b/src/c_fl_file_input.cpp
index 49cb873..1af9e19 100644
--- a/src/c_fl_file_input.cpp
+++ b/src/c_fl_file_input.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_File_Input.H>
#include "c_fl_file_input.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_float_input.cpp b/src/c_fl_float_input.cpp
index 7e9278a..a9ac50e 100644
--- a/src/c_fl_float_input.cpp
+++ b/src/c_fl_float_input.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Float_Input.H>
#include "c_fl_float_input.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_group.cpp b/src/c_fl_group.cpp
index 88fe477..4f1b5ef 100644
--- a/src/c_fl_group.cpp
+++ b/src/c_fl_group.cpp
@@ -4,16 +4,7 @@
#include <FL/Fl_Widget.H>
#include "c_fl_group.h"
#include "c_fl_widget.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_input.cpp b/src/c_fl_input.cpp
index e215d38..7afc5b6 100644
--- a/src/c_fl_input.cpp
+++ b/src/c_fl_input.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Input.H>
#include "c_fl_input.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_int_input.cpp b/src/c_fl_int_input.cpp
index c7db8ef..1497c0d 100644
--- a/src/c_fl_int_input.cpp
+++ b/src/c_fl_int_input.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Int_Input.H>
#include "c_fl_int_input.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_light_button.cpp b/src/c_fl_light_button.cpp
index 4dfa893..df1a02e 100644
--- a/src/c_fl_light_button.cpp
+++ b/src/c_fl_light_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Light_Button.H>
#include "c_fl_light_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_menu.cpp b/src/c_fl_menu.cpp
index 8a8b974..a037ccb 100644
--- a/src/c_fl_menu.cpp
+++ b/src/c_fl_menu.cpp
@@ -3,16 +3,7 @@
#include <FL/Fl_Menu_.H>
#include <FL/Fl_Menu_Item.H>
#include "c_fl_menu.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_menu_bar.cpp b/src/c_fl_menu_bar.cpp
index 947a6ce..ec94607 100644
--- a/src/c_fl_menu_bar.cpp
+++ b/src/c_fl_menu_bar.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Menu_Bar.H>
#include "c_fl_menu_bar.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_menu_button.cpp b/src/c_fl_menu_button.cpp
index bc782a4..c09cf37 100644
--- a/src/c_fl_menu_button.cpp
+++ b/src/c_fl_menu_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Menu_Button.H>
#include "c_fl_menu_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_menu_window.cpp b/src/c_fl_menu_window.cpp
index 6a6c45d..7e186d7 100644
--- a/src/c_fl_menu_window.cpp
+++ b/src/c_fl_menu_window.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Menu_Window.H>
#include "c_fl_menu_window.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_multiline_input.cpp b/src/c_fl_multiline_input.cpp
index 3d6cb09..b726310 100644
--- a/src/c_fl_multiline_input.cpp
+++ b/src/c_fl_multiline_input.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Multiline_Input.H>
#include "c_fl_multiline_input.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_multiline_output.cpp b/src/c_fl_multiline_output.cpp
index a8d52e7..c7da41e 100644
--- a/src/c_fl_multiline_output.cpp
+++ b/src/c_fl_multiline_output.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Multiline_Output.H>
#include "c_fl_multiline_output.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_output.cpp b/src/c_fl_output.cpp
index bae40d6..da4ba3f 100644
--- a/src/c_fl_output.cpp
+++ b/src/c_fl_output.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Output.H>
#include "c_fl_output.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_radio_button.cpp b/src/c_fl_radio_button.cpp
index 45f07b9..643e8e1 100644
--- a/src/c_fl_radio_button.cpp
+++ b/src/c_fl_radio_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Radio_Button.H>
#include "c_fl_radio_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_radio_light_button.cpp b/src/c_fl_radio_light_button.cpp
index 3ffea4f..ae071a3 100644
--- a/src/c_fl_radio_light_button.cpp
+++ b/src/c_fl_radio_light_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Radio_Light_Button.H>
#include "c_fl_radio_light_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_radio_round_button.cpp b/src/c_fl_radio_round_button.cpp
index 12d043f..1a69432 100644
--- a/src/c_fl_radio_round_button.cpp
+++ b/src/c_fl_radio_round_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Radio_Round_Button.H>
#include "c_fl_radio_round_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_repeat_button.cpp b/src/c_fl_repeat_button.cpp
index 645f911..59bdc4a 100644
--- a/src/c_fl_repeat_button.cpp
+++ b/src/c_fl_repeat_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Repeat_Button.H>
#include "c_fl_repeat_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_return_button.cpp b/src/c_fl_return_button.cpp
index 11a7a9b..5b03ebf 100644
--- a/src/c_fl_return_button.cpp
+++ b/src/c_fl_return_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Return_Button.H>
#include "c_fl_return_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_round_button.cpp b/src/c_fl_round_button.cpp
index 02d6330..cbe5f19 100644
--- a/src/c_fl_round_button.cpp
+++ b/src/c_fl_round_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Round_Button.H>
#include "c_fl_round_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_secret_input.cpp b/src/c_fl_secret_input.cpp
index 4fc524d..c86e7b2 100644
--- a/src/c_fl_secret_input.cpp
+++ b/src/c_fl_secret_input.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Secret_Input.H>
#include "c_fl_secret_input.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_single_window.cpp b/src/c_fl_single_window.cpp
index e20bb80..2b66b3d 100644
--- a/src/c_fl_single_window.cpp
+++ b/src/c_fl_single_window.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Single_Window.H>
#include "c_fl_single_window.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_text_display.cpp b/src/c_fl_text_display.cpp
index 0114d8d..8ae0f01 100644
--- a/src/c_fl_text_display.cpp
+++ b/src/c_fl_text_display.cpp
@@ -4,16 +4,7 @@
#include <FL/Fl_Text_Buffer.H>
#include "c_fl_text_display.h"
#include "c_fl_text_buffer.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_text_editor.cpp b/src/c_fl_text_editor.cpp
index 6608af9..1056133 100644
--- a/src/c_fl_text_editor.cpp
+++ b/src/c_fl_text_editor.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Text_Editor.H>
#include "c_fl_text_editor.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_toggle_button.cpp b/src/c_fl_toggle_button.cpp
index c4da149..2ecfb70 100644
--- a/src/c_fl_toggle_button.cpp
+++ b/src/c_fl_toggle_button.cpp
@@ -2,16 +2,7 @@
#include <FL/Fl_Toggle_Button.H>
#include "c_fl_toggle_button.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_type.h b/src/c_fl_type.h
new file mode 100644
index 0000000..750ae6c
--- /dev/null
+++ b/src/c_fl_type.h
@@ -0,0 +1,16 @@
+
+
+#ifndef FL_TYPE_GUARD
+#define FL_TYPE_GUARD
+
+
+typedef void (d_hook)(void*);
+typedef d_hook* d_hook_p;
+
+
+typedef int (h_hook)(void*,int);
+typedef h_hook* h_hook_p;
+
+
+#endif
+
diff --git a/src/c_fl_widget.cpp b/src/c_fl_widget.cpp
index d13d612..1e3e3a4 100644
--- a/src/c_fl_widget.cpp
+++ b/src/c_fl_widget.cpp
@@ -3,16 +3,7 @@
#include <FL/Fl_Widget.H>
#include <FL/Fl_Image.H>
#include "c_fl_widget.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"
diff --git a/src/c_fl_window.cpp b/src/c_fl_window.cpp
index e6f0adb..dba9ac1 100644
--- a/src/c_fl_window.cpp
+++ b/src/c_fl_window.cpp
@@ -3,16 +3,7 @@
#include <FL/Fl_Window.H>
#include <FL/Fl_RGB_Image.H>
#include "c_fl_window.h"
-
-
-
-
-typedef void (d_hook)(void*);
-typedef d_hook* d_hook_p;
-
-
-typedef int (h_hook)(void*,int);
-typedef h_hook* h_hook_p;
+#include "c_fl_type.h"