summaryrefslogtreecommitdiff
path: root/src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2026-01-04 16:45:11 +0100
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2026-01-04 16:45:11 +0100
commit46e681561241d0a123dfc08c234745c40c4a262a (patch)
tree96e7f272127d5ba050222832f0fb5cc950c2f3a3 /src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx
parent0e570fb6729ff6b97249256c2c9d5f3aa58c7bb4 (diff)
Windows: improve moving window across screens having distinct scale factors.
Diffstat (limited to 'src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx')
-rw-r--r--src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx b/src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx
index 375408496..8e199b09c 100644
--- a/src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx
+++ b/src/drivers/WinAPI/Fl_WinAPI_Gl_Window_Driver.cxx
@@ -454,6 +454,19 @@ void Fl_WinAPI_Gl_Window_Driver::switch_back() {
}
+class Fl_WinAPI_Gl_Plugin : public Fl_WinAPI_Plugin {
+public:
+ Fl_WinAPI_Gl_Plugin() : Fl_WinAPI_Plugin(name()) { }
+ const char *name() override { return "gl.winapi.fltk.org"; }
+ void invalidate(Fl_Window *w) override {
+ w->as_gl_window()->valid(0);
+ }
+};
+
+
+static Fl_WinAPI_Gl_Plugin Gl_Invalidate_Plugin;
+
+
FL_EXPORT HGLRC fl_win32_glcontext(GLContext rc) { return (HGLRC)rc; }
#endif // HAVE_GL