From 84eeac5892c47c657deb961ef3aa88076c8ad651 Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Wed, 25 Sep 2024 10:23:47 +0200 Subject: Fix issue about Fl_Tabs and maximizing window under Windows (#1075) --- src/Fl_Tabs.cxx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Fl_Tabs.cxx b/src/Fl_Tabs.cxx index ffca48f11..89394ac05 100644 --- a/src/Fl_Tabs.cxx +++ b/src/Fl_Tabs.cxx @@ -528,6 +528,7 @@ int Fl_Tabs::handle(int event) { static int initial_x = 0; static int initial_tab_offset = 0; static int forward_motion_to_group = 0; + static Fl_Widget *o_push_drag = NULL; Fl_Widget *o; int i; @@ -563,11 +564,15 @@ int Fl_Tabs::handle(int event) { } /* FALLTHROUGH */ case FL_DRAG: + o_push_drag = which(Fl::event_x(), Fl::event_y()); case FL_RELEASE: if (forward_motion_to_group) { return Fl_Group::handle(event); } o = which(Fl::event_x(), Fl::event_y()); + if (event == FL_RELEASE && o != o_push_drag) { // see issue #1075 + return 1; + } if ( (overflow_type == OVERFLOW_DRAG) || (overflow_type == OVERFLOW_PULLDOWN) ) { if (tab_pos[children()] < w() && tab_offset == 0) { // fall through -- cgit v1.2.3