From 28169f14ec80f07874464412c72d7523a7768d81 Mon Sep 17 00:00:00 2001 From: Mattia Barbon Date: Sun, 4 May 2003 12:19:57 +0000 Subject: [PATCH] Fix for the fact that unmapped but managed widgets intercept mouse events even if they are not visible. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@20466 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/motif/window.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/motif/window.cpp b/src/motif/window.cpp index cc55da5b8d..855d4e1785 100644 --- a/src/motif/window.cpp +++ b/src/motif/window.cpp @@ -172,10 +172,18 @@ bool wxWindow::MapOrUnmap(WXWidget widget, bool domap) if ( !w ) return FALSE; + // if the widget is not unmanaged, it still intercepts + // mouse events, even if it is not mapped (and hence invisible) if ( domap ) + { + XtManageChild(w); XtMapWidget(w); + } else + { XtUnmapWidget(w); + XtUnmanageChild(w); + } // Rationale: a lot of common operations (including but not // limited to moving, resizing and appending items to a listbox) -- 2.47.2