Fix state of visible() flag after Fl_Window(x, y, w, h, t).
The doc states: "Top-level windows initially have visible() set to 0 and parent() set to NULL. Subwindows initially have visible() set to 1 and parent() set to the parent window pointer." The first statement was not satisfied when a window was constructed with the Fl_Window(x, y, w, h, t) constructor.
This commit is contained in:
parent
7cb0c2311c
commit
d068fbf9de
@ -74,6 +74,7 @@ Fl_Window::Fl_Window(int X,int Y,int W, int H, const char *l) :
|
||||
{
|
||||
_Fl_Window();
|
||||
set_flag(FORCE_POSITION);
|
||||
if (!parent()) clear_visible();
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user