Author: matt
Date: 2007-06-18 04:43:37 -0400 (Mon, 18 Jun 2007)
New Revision: 5911
Log:
STR #1706: mapping a subwindow with an unmapped parent window would crash under
X11.
Modified:
branches/branch-1.1/CHANGES
branches/branch-1.1/src/Fl_x.cxx
Modified: branches/branch-1.1/CHANGES
===================================================================
--- branches/branch-1.1/CHANGES 2007-06-17 16:04:31 UTC (rev 5910)
+++ branches/branch-1.1/CHANGES 2007-06-18 08:43:37 UTC (rev 5911)
@@ -3,6 +3,8 @@
- Documentation fixes (STR #1454, STR #1455, STR #1456,
STR #1457, STR #1458, STR #1460, STR #1481, STR #1578,
STR #1639, STR #1645, STR #1644)
+ - Fixed mapping of subwindows with unmapped parent
+ windows (STR #1706)
- Fixed rendering of grayscale images with alpha
channel (STR #1703)
- Fixed occasional incomplete refresh (STR #1681)
Modified: branches/branch-1.1/src/Fl_x.cxx
===================================================================
--- branches/branch-1.1/src/Fl_x.cxx 2007-06-17 16:04:31 UTC (rev 5910)
+++ branches/branch-1.1/src/Fl_x.cxx 2007-06-18 08:43:37 UTC (rev 5911)
@@ -1134,6 +1134,14 @@
if (Y < scr_y) Y = scr_y;
}
+ // if the window is a subwindow and our parent is not mapped, we
+ // mark this window visible, so that mapping the parent later will
+ // call this function again.
+ if (win->parent() && !Fl_X::i(win->window())) {
+ win->set_visible();
+ return;
+ }
+
ulong root = win->parent() ?
fl_xid(win->window()) : RootWindow(fl_display, fl_screen);
_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit