diff --git a/fluid/Fl_Button_Type.cxx b/fluid/Fl_Button_Type.cxx index 16541224a..7de4895a1 100644 --- a/fluid/Fl_Button_Type.cxx +++ b/fluid/Fl_Button_Type.cxx @@ -1,5 +1,5 @@ // -// Widget factory code for the Fast Light Tool Kit (FLTK). +// Button type factory code for the Fast Light Tool Kit (FLTK). // // Type classes for most of the fltk widgets. Most of the work // is done by code in Fl_Widget_Type.C. Also a factory instance @@ -9,7 +9,7 @@ // to a factory instance for every class (both the ones defined // here and ones in other files) // -// Copyright 1998-2017 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 @@ -24,52 +24,15 @@ #include "Fl_Button_Type.h" -#include "fluid.h" -#include "Fl_Window_Type.h" -#include "Fl_Group_Type.h" #include "Fd_Snap_Action.h" -#include "pixmaps.h" -#include "undo.h" #include -#include -#include -#include #include -#include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include #include -#include -#include -#include #include #include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include "../src/flstring.h" - -#include -#include // ---- Button Types --------------------------------------------------- MARK: - @@ -84,17 +47,17 @@ static Fl_Menu_Item buttontype_menu[] = { {0} }; -Fl_Menu_Item *Fl_Button_Type::subtypes() FL_OVERRIDE { +Fl_Menu_Item *Fl_Button_Type::subtypes() { return buttontype_menu; } -void Fl_Button_Type::ideal_size(int &w, int &h) FL_OVERRIDE { +void Fl_Button_Type::ideal_size(int &w, int &h) { h = layout->labelsize + 8; w = layout->labelsize * 4 + 8; Fd_Snap_Action::better_size(w, h); } -Fl_Widget *Fl_Button_Type::widget(int x, int y, int w, int h) FL_OVERRIDE { +Fl_Widget *Fl_Button_Type::widget(int x, int y, int w, int h) { return new Fl_Button(x, y, w, h, "Button"); } diff --git a/fluid/Fl_Button_Type.h b/fluid/Fl_Button_Type.h index f80a60beb..2013e1646 100644 --- a/fluid/Fl_Button_Type.h +++ b/fluid/Fl_Button_Type.h @@ -1,7 +1,7 @@ // -// Widget type header file for the Fast Light Tool Kit (FLTK). +// Button type header file for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2021 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 @@ -30,7 +30,7 @@ public: void ideal_size(int &w, int &h) FL_OVERRIDE; const char *type_name() FL_OVERRIDE { return "Fl_Button"; } const char *alt_type_name() FL_OVERRIDE { return "fltk::Button"; } - Fl_Widget *widget(int x, int y, int w, int h); + Fl_Widget *widget(int x, int y, int w, int h) FL_OVERRIDE; Fl_Widget_Type *_make() FL_OVERRIDE { return new Fl_Button_Type(); } int is_button() const FL_OVERRIDE { return 1; } ID id() const FL_OVERRIDE { return ID_Button; } diff --git a/fluid/factory.cxx b/fluid/factory.cxx index 43139403b..26ea50aef 100644 --- a/fluid/factory.cxx +++ b/fluid/factory.cxx @@ -9,7 +9,7 @@ // to a factory instance for every class (both the ones defined // here and ones in other files) // -// Copyright 1998-2017 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 @@ -25,7 +25,6 @@ #include "factory.h" #include "fluid.h" -#include "Fl_Window_Type.h" #include "Fl_Group_Type.h" #include "Fd_Snap_Action.h" #include "pixmaps.h" @@ -35,26 +34,17 @@ #include #include #include -#include #include -#include #include #include #include #include #include -#include -#include #include #include -#include #include #include -#include #include -#include -#include -#include #include #include #include