Add back WINVER check to fix VC6 compilation of wxMSW.

The changes of r72953 removed the check for WINVER around the code using
COMBOBOXINFO but it's still needed with VC^, so restore it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72958 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2012-11-15 12:22:05 +00:00
parent 12fdbd3d6a
commit 7bc572ec82

View File

@ -631,6 +631,9 @@ wxSize wxChoice::DoGetSizeFromTextSize(int xlen, int ylen) const
// and its child part. I.e. arrow, separators, etc.
wxSize tsize(xlen, 0);
// FIXME-VC6: Only VC6 needs this guard, see WINVER definition in
// include/wx/msw/wrapwin.h
#if defined(WINVER) && WINVER >= 0x0500
WinStruct<COMBOBOXINFO> info;
if ( MSWGetComboBoxInfo(&info) )
{
@ -638,6 +641,7 @@ wxSize wxChoice::DoGetSizeFromTextSize(int xlen, int ylen) const
+ info.rcItem.left + 3; // right and extra margins
}
else // Just use some rough approximation.
#endif // WINVER >= 0x0500
{
tsize.x += 4*cHeight;
}