> I am using MFC with an FLTK based application. I have > successfully isolated > MFC and FLTK app starts up fine. However, the MFC based > static library that > I am using expects an MFC app and passes the hWnd value returned by > AfxGetMainWnd() in its ::SetTimer() function. I think that > this hWnd value > is not being correctly passed to SetTimer. Since each window > on Windows > platform has an hWnd (a window handle, that is), I wonder if > there is a way > to obtain this window handle (hWnd) from FLTK. If I can have > this hWnd then > I can pass this hWnd to the initialization function of this > library and have > the library use this passed hWnd instead.
Based on earlier reports, mixing FLTK and MFC has been a recipe for pain and trouble, so I'd advise against it. But if you are keen - good luck, though you may be on your own out there! That said: If what you need is to get the HWND for a given fltk window, then you need to use - HWND fl_xid(const Fl_Window *); Returns the window handle for a Fl_Window, or zero if not shown(). (Actually, this may be guarded by the FL_INTERNALS flag these days, not sure, but you can still use it.) SELEX Galileo Ltd Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 3EL A company registered in England & Wales. Company no. 02426132 ******************************************************************** This email and any attachments are confidential to the intended recipient and may also be privileged. If you are not the intended recipient please delete it from your system and notify the sender. You should not copy it or use it for any purpose nor disclose or distribute its contents to any other person. ******************************************************************** _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

