diff options
| author | Matthias Melcher <github@matthiasm.com> | 2022-12-30 19:14:36 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-12-30 19:14:36 +0100 |
| commit | 44c874b731f9f58c2f50c3c6076371058cbe26e3 (patch) | |
| tree | 2386dfcc700c41a1109fc78b96875c11056abcc9 /src/Fl_Screen_Driver.H | |
| parent | f58a93a159105336136ce6e54ab7fc161e4fa15a (diff) | |
Use `FL_OVERRIDE` for all overridden virtual methods (#611)
FL_OVERRIDE is defined as `override` for C++11 and higher
FL_OVERRIDE is defined as `override` for VisualC 2015 and newer
Don't interfere with Fl_Widget::override()
Diffstat (limited to 'src/Fl_Screen_Driver.H')
| -rw-r--r-- | src/Fl_Screen_Driver.H | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Fl_Screen_Driver.H b/src/Fl_Screen_Driver.H index 7ccbc67e9..38070df5a 100644 --- a/src/Fl_Screen_Driver.H +++ b/src/Fl_Screen_Driver.H @@ -109,8 +109,8 @@ public: virtual void init() {} virtual int x() { return 0; } virtual int y() { return 0; } - virtual int w() { return 800; } // default, override in driver! - virtual int h() { return 600; } // default, override in driver! + virtual int w() { return 800; } // default, FL_OVERRIDE in driver! + virtual int h() { return 600; } // default, FL_OVERRIDE in driver! virtual int screen_count(); void screen_xywh(int &X, int &Y, int &W, int &H, int mx, int my); virtual void screen_xywh(int &X, int &Y, int &W, int &H, int /*n*/) { @@ -122,7 +122,7 @@ public: void screen_xywh(int &X, int &Y, int &W, int &H, int mx, int my, int mw, int mh); virtual int screen_num(int x, int y); virtual int screen_num(int x, int y, int w, int h); - virtual void screen_dpi(float &h, float &v, int n = 0) { // override in driver! + virtual void screen_dpi(float &h, float &v, int n = 0) { // FL_OVERRIDE in driver! h = 72; v = 72; (void)n; @@ -134,7 +134,7 @@ public: // --- audible output virtual void beep(int) {} // --- global events - virtual void flush() {} // must override + virtual void flush() {} // must FL_OVERRIDE virtual void grab(Fl_Window *) {} // --- global colors /* the default implementation of parse_color() may be enough */ |
