From 225c3d6da316838aba9432a319bbdd33da97a001 Mon Sep 17 00:00:00 2001 From: Manolo Gouy Date: Tue, 25 Jul 2017 10:57:24 +0000 Subject: Rewrite Fl_Window_Driver::resize_after_scale_change() removing calls to Fl_Window::hide() and Fl_Window::show(). Windows are now rescaled with a call to Fl_Window::resize() which has been slightly modified. Static member variable bool Fl_Window_Driver::in_resize_after_scale_change is created, and is true if and only if Fl_Window::resize() is called by Fl_Window_Driver::resize_after_scale_change(). This new flag allows Fl_Window::resize() to perform correctly the rescaling of the window. Fl_Gl_Window::resize() and Fl_Double_Window::resize() also consult the value of the Fl_Window_Driver::in_resize_after_scale_change flag. The platform-specific Fl_WinAPI_Window_Driver::resize() and Fl_X11_Window_Driver::resize() also use the Fl_Window_Driver::in_resize_after_scale_change flag. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12349 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- FL/Fl_Window_Driver.H | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'FL') diff --git a/FL/Fl_Window_Driver.H b/FL/Fl_Window_Driver.H index 3035b330b..1ce201370 100644 --- a/FL/Fl_Window_Driver.H +++ b/FL/Fl_Window_Driver.H @@ -44,13 +44,16 @@ class FL_EXPORT Fl_Window_Driver { friend class Fl_Window; friend class Fl_X; + friend class Fl_Group; + friend class Fl_Gl_Window; + friend class Fl_Double_Window; protected: Fl_Window *pWindow; struct shape_data_type; shape_data_type *shape_data_; ///< non-null means the window has a non-rectangular shape void flush_Fl_Window(); // accessor to protected Fl_Window::flush() - + static bool in_resize_after_scale_change; public: Fl_Window_Driver(Fl_Window *); virtual ~Fl_Window_Driver(); -- cgit v1.2.3