diff options
| author | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2019-06-21 21:47:00 +0200 |
|---|---|---|
| committer | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2019-06-21 21:47:00 +0200 |
| commit | 35376256e2da9bb517dc9c184d319f46490a21c2 (patch) | |
| tree | d2c667a23b94c1ebb5e4d65ba0cd0c82d2929be9 | |
| parent | 71f645a6ed0522bc49fe57f8cabf17f2a1e0b29e (diff) | |
Simpler list of virtual member functions of Fl_Gl_Window_Driver
| -rw-r--r-- | src/Fl_Gl_Overlay.cxx | 7 | ||||
| -rw-r--r-- | src/Fl_Gl_Window.cxx | 2 | ||||
| -rw-r--r-- | src/Fl_Gl_Window_Driver.H | 7 |
3 files changed, 6 insertions, 10 deletions
diff --git a/src/Fl_Gl_Overlay.cxx b/src/Fl_Gl_Overlay.cxx index c10b6f068..ab969d447 100644 --- a/src/Fl_Gl_Overlay.cxx +++ b/src/Fl_Gl_Overlay.cxx @@ -224,18 +224,15 @@ void Fl_X11_Gl_Window_Driver::make_overlay(void *¤t) { //////////////////////////////////////////////////////////////// // Windows version: -void Fl_WinAPI_Gl_Window_Driver::hide_overlay(void *& overlay) { #if HAVE_GL_OVERLAY +void Fl_WinAPI_Gl_Window_Driver::gl_hide_before(void *& overlay) { if (overlay && overlay != pWindow) { delete_gl_context((GLContext)overlay); overlay = 0; } -#endif } +#endif -void Fl_WinAPI_Gl_Window_Driver::hide_overlay() { - Fl_Gl_Window_Driver::hide_overlay(); -} void Fl_WinAPI_Gl_Window_Driver::make_overlay_current() { #if HAVE_GL_OVERLAY diff --git a/src/Fl_Gl_Window.cxx b/src/Fl_Gl_Window.cxx index 43e2f67ab..5677447ce 100644 --- a/src/Fl_Gl_Window.cxx +++ b/src/Fl_Gl_Window.cxx @@ -290,7 +290,7 @@ void Fl_Gl_Window::context(GLContext v, int destroy_flag) { */ void Fl_Gl_Window::hide() { context(0); - pGlWindowDriver->hide_overlay(overlay); + pGlWindowDriver->gl_hide_before(overlay); Fl_Window::hide(); } diff --git a/src/Fl_Gl_Window_Driver.H b/src/Fl_Gl_Window_Driver.H index 9d28c1f22..56dbbcf69 100644 --- a/src/Fl_Gl_Window_Driver.H +++ b/src/Fl_Gl_Window_Driver.H @@ -62,7 +62,7 @@ public: virtual void resize(int is_a_resize, int w, int h) {} virtual char swap_type(); virtual int flush_begin(char& valid_f) {return 0;} - virtual void hide_overlay(void *& overlay) {} + virtual void gl_hide_before(void *& overlay) {} // the default implementation may be enough static Fl_Gl_Choice *find_begin(int m, const int *alistp); // Return one of these structures for a given gl mode. // The second argument is a glX attribute list, and is used if mode is zero. @@ -72,7 +72,7 @@ public: virtual void set_gl_context(Fl_Window* w, GLContext context) {} virtual void delete_gl_context(GLContext) {} virtual void make_overlay(void* &o); - virtual void hide_overlay() {} + virtual void hide_overlay() {} // the default implementation may be enough virtual void make_overlay_current() {} virtual void redraw_overlay() {} virtual int can_do_overlay() {return 0;} @@ -135,8 +135,6 @@ class Fl_WinAPI_Gl_Window_Driver : public Fl_Gl_Window_Driver { virtual void swap_buffers(); virtual void invalidate() {} virtual int flush_begin(char& valid_f); - virtual void hide_overlay(void *& overlay); - virtual void hide_overlay(); virtual Fl_Gl_Choice *find(int m, const int *alistp); virtual GLContext create_gl_context(Fl_Window* window, const Fl_Gl_Choice* g, int layer = 0); virtual void set_gl_context(Fl_Window* w, GLContext context); @@ -149,6 +147,7 @@ class Fl_WinAPI_Gl_Window_Driver : public Fl_Gl_Window_Driver { virtual void get_list(Fl_Font_Descriptor *fd, int r); virtual int genlistsize(); #if HAVE_GL_OVERLAY + virtual void gl_hide_before(void *& overlay); virtual int can_do_overlay(); virtual int overlay_color(Fl_Color i); void make_overlay(void*&overlay); |
