Remove obsolete wxCHECK_W32API_VERSION() checks
The latest of those checks tested for w32 API 3.3, which is older than
MinGW 3.4 released which is more than 13 years old, so we can safely
drop them (let alone checks for prehistoric 0.5 w32 API).
This incidentally fixes compilation errors due to the use of
wxCHECK_W32API_VERSION() in wx/msw/winundef.h which was now (since
the changes of 8c572c0a77
) included before
this macro was defined.
This commit is contained in:
parent
808c842edd
commit
406608b31c
@ -108,7 +108,7 @@
|
||||
#elif defined(__BORLANDC__) && (__BORLANDC__ >= 0x520)
|
||||
#define wxHAVE_TCHAR_SUPPORT
|
||||
#include <ctype.h>
|
||||
#elif defined(__MINGW32__) && wxCHECK_W32API_VERSION( 1, 0 )
|
||||
#elif defined(__MINGW32__)
|
||||
#define wxHAVE_TCHAR_SUPPORT
|
||||
#include <stddef.h>
|
||||
#include <string.h>
|
||||
|
@ -127,8 +127,7 @@ enum wxPosixPermissions
|
||||
( \
|
||||
defined(__VISUALC__) || \
|
||||
defined(__MINGW64_TOOLCHAIN__) || \
|
||||
(defined(__MINGW32__) && !defined(__WINE__) && \
|
||||
wxCHECK_W32API_VERSION(0, 5)) || \
|
||||
(defined(__MINGW32__) && !defined(__WINE__)) || \
|
||||
defined(__BORLANDC__) \
|
||||
)
|
||||
|
||||
|
@ -100,46 +100,6 @@
|
||||
#define __CYGWIN10__
|
||||
#endif
|
||||
|
||||
/* Mingw runtime 1.0-20010604 has some missing _tXXXX functions,
|
||||
so let's define them ourselves: */
|
||||
#if defined(__GNUWIN32__) && wxCHECK_W32API_VERSION( 1, 0 ) \
|
||||
&& !wxCHECK_W32API_VERSION( 1, 1 )
|
||||
#ifndef _tsetlocale
|
||||
#if wxUSE_UNICODE
|
||||
#define _tsetlocale _wsetlocale
|
||||
#else
|
||||
#define _tsetlocale setlocale
|
||||
#endif
|
||||
#endif
|
||||
#ifndef _tgetenv
|
||||
#if wxUSE_UNICODE
|
||||
#define _tgetenv _wgetenv
|
||||
#else
|
||||
#define _tgetenv getenv
|
||||
#endif
|
||||
#endif
|
||||
#ifndef _tfopen
|
||||
#if wxUSE_UNICODE
|
||||
#define _tfopen _wfopen
|
||||
#else
|
||||
#define _tfopen fopen
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* current (= before mingw-runtime 3.3) mingw32 headers forget to
|
||||
define _puttchar, this will probably be fixed in the next versions but
|
||||
for now do it ourselves
|
||||
*/
|
||||
#if defined( __MINGW32__ ) && \
|
||||
!wxCHECK_MINGW32_VERSION(3,3) && !defined( _puttchar )
|
||||
#ifdef wxUSE_UNICODE
|
||||
#define _puttchar putwchar
|
||||
#else
|
||||
#define _puttchar puttchar
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/*
|
||||
Traditional MinGW (but not MinGW-w64 nor TDM-GCC) omits many POSIX
|
||||
functions from their headers when compiled with __STRICT_ANSI__ defined.
|
||||
|
@ -246,27 +246,6 @@
|
||||
#ifndef TVM_SETBKCOLOR
|
||||
#define TVM_SETBKCOLOR (TV_FIRST + 29)
|
||||
#define TVM_SETTEXTCOLOR (TV_FIRST + 30)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* The following are specifically required for MinGW.
|
||||
*/
|
||||
|
||||
#if defined (__MINGW32__)
|
||||
|
||||
#if !wxCHECK_W32API_VERSION(3,1)
|
||||
|
||||
#include <windows.h>
|
||||
#include "wx/msw/winundef.h"
|
||||
|
||||
typedef struct
|
||||
{
|
||||
RECT rgrc[3];
|
||||
WINDOWPOS *lppos;
|
||||
} NCCALCSIZE_PARAMS, *LPNCCALCSIZE_PARAMS;
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
// Various defines used by the webview library that are needed by mingw
|
||||
|
@ -252,15 +252,6 @@
|
||||
#ifdef StartDoc
|
||||
#undef StartDoc
|
||||
|
||||
// Work around a bug in very old MinGW headers that didn't define DOCINFOW
|
||||
// and DOCINFOA but only DOCINFO in both ANSI and Unicode.
|
||||
#if defined( __GNUG__ )
|
||||
#if !wxCHECK_W32API_VERSION( 0, 5 )
|
||||
#define DOCINFOW DOCINFO
|
||||
#define DOCINFOA DOCINFO
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef _UNICODE
|
||||
inline int StartDoc(HDC h, CONST DOCINFOW* info)
|
||||
{
|
||||
|
@ -1650,12 +1650,7 @@ bool wxFileName::GetShortcutTarget(const wxString& shortcutPath,
|
||||
if (SUCCEEDED(hres))
|
||||
{
|
||||
wxChar buf[2048];
|
||||
// Wrong prototype in early versions
|
||||
#if defined(__MINGW32__) && !wxCHECK_W32API_VERSION(2, 2)
|
||||
psl->GetPath((CHAR*) buf, 2048, NULL, SLGP_UNCPRIORITY);
|
||||
#else
|
||||
psl->GetPath(buf, 2048, NULL, SLGP_UNCPRIORITY);
|
||||
#endif
|
||||
targetFilename = wxString(buf);
|
||||
success = (shortcutPath != targetFilename);
|
||||
|
||||
|
@ -49,7 +49,6 @@ wxDEFINE_EVENT( wxEVT_DIALUP_DISCONNECTED, wxDialUpEvent );
|
||||
// Doesn't yet compile under BC++
|
||||
// Wine: no wininet.h
|
||||
#if (!defined(__BORLANDC__) || (__BORLANDC__>=0x550)) && \
|
||||
(!defined(__GNUWIN32__) || wxCHECK_W32API_VERSION(0, 5)) && \
|
||||
!defined(__WINE__)
|
||||
|
||||
#include <ras.h>
|
||||
|
@ -393,12 +393,10 @@ WXDWORD wxListCtrl::MSWGetStyle(long style, WXDWORD *exstyle) const
|
||||
else if ( style & wxLC_SORT_DESCENDING )
|
||||
wstyle |= LVS_SORTDESCENDING;
|
||||
|
||||
#if !( defined(__GNUWIN32__) && !wxCHECK_W32API_VERSION( 1, 0 ) )
|
||||
if ( style & wxLC_VIRTUAL )
|
||||
{
|
||||
wstyle |= LVS_OWNERDATA;
|
||||
}
|
||||
#endif // ancient cygwin
|
||||
|
||||
return wstyle;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user