STR #1057: A window that is needed to correctly manage a timer on WIN32 (personally, I would like to mark this WTF ;-), was actually visible. I resized it to 0x0 ixels, but if that fails, we fall back to the old 1x1 pixels. I also removed the "default" positioning since that messes up the default window stacking for pedantic users.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4614 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
134629c861
commit
e7ea8bbe97
@ -1383,11 +1383,18 @@ void Fl::repeat_timeout(double time, Fl_Timeout_Handler cb, void* data)
|
||||
wc.hInstance = fl_display;
|
||||
wc.lpszClassName = timer_class;
|
||||
ATOM atom = RegisterClassEx(&wc);
|
||||
|
||||
// create a zero size window to handle timer events
|
||||
s_TimerWnd = CreateWindowEx(WS_EX_LEFT | WS_EX_TOOLWINDOW,
|
||||
timer_class, "",
|
||||
WS_POPUP,
|
||||
CW_USEDEFAULT, CW_USEDEFAULT, 1, 1,
|
||||
0, 0, 0, 0,
|
||||
NULL, NULL, fl_display, NULL);
|
||||
// just in case this OS won't let us create a 0x0 size window:
|
||||
if (!s_TimerWnd)
|
||||
s_TimerWnd = CreateWindowEx(WS_EX_LEFT | WS_EX_TOOLWINDOW,
|
||||
timer_class, "",
|
||||
WS_POPUP,
|
||||
0, 0, 1, 1,
|
||||
NULL, NULL, fl_display, NULL);
|
||||
ShowWindow(s_TimerWnd, SW_SHOWNOACTIVATE);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user