[wx-dev] Compile error in src/msw/display.cpp
Vadim Zeitlin
vadim at wxwindows.org
Wed Nov 1 06:39:21 PST 2006
On Wed, 01 Nov 2006 05:14:58 +0000 Wlodek Szafran <wlodek.szafran at hwcn.org> wrote:
WS> On 10/31/2006 5:33 PM, Vadim Zeitlin wrote:
WS> > WS> and src/msw/display.cpp still doesn't compile (without including
WS> > WS> wrapwin.h in the way mentioned earlier) as it has the symbols I
WS> > WS> mentioned earlier still undefined.
WS> >
WS> > But I don't understand this one: something must define WINVER
WS> > [incorrectly] if this happens but I don't see where does it happen, do you?
WS>
WS> WINVER is now getting defined in wx/db.h, where windows.h is included
WS> directly.
Indeed, thanks. I didn't notice it as wxUSE_ODBC is the default 0 in my
builds.
WS> When the inclusions of windows.h in wx/db.h are replaced with
WS> those of wx/msw/wrapwin.h, things look good at last -- if wxUSE_ODBC is
WS> defined, wrapwin.h is included from wx/db.h, if it's not defined, then
WS> wrapwin.h gets included from wx/msw/app.h and src/msw/display.cpp
WS> compiles smoothly, without the need of including wrapwin.h there.
I think it's better to continue to include it from there. The inclusion of
wx/msw/wrapwin.h (and hence <windows.h>) from wx/app.h is bad and while I
don't see how can we get rid of it right now it might still happen in the
future and then display.cpp would be broken again.
Thanks for your fixes!
VZ
More information about the wx-dev
mailing list