Readd mingw32 support

Clean-up


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2651 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Brian Macy
1999-06-02 15:46:54 +00:00
parent 70d1b3cf88
commit 379a3b04b9

View File

@@ -18,9 +18,6 @@
#ifdef GetCharWidth #ifdef GetCharWidth
#undef GetCharWidth #undef GetCharWidth
#endif
#ifndef __WIN16__
inline BOOL GetCharWidth(HDC dc, UINT first, UINT last, LPINT buffer) inline BOOL GetCharWidth(HDC dc, UINT first, UINT last, LPINT buffer)
{ {
#ifdef _UNICODE #ifdef _UNICODE
@@ -35,9 +32,6 @@ inline BOOL GetCharWidth(HDC dc, UINT first, UINT last, LPINT buffer)
#ifdef FindWindow #ifdef FindWindow
#undef FindWindow #undef FindWindow
#endif
#ifndef __WIN16__
#ifdef _UNICODE #ifdef _UNICODE
inline HWND FindWindow(LPCWSTR classname, LPCWSTR windowname) inline HWND FindWindow(LPCWSTR classname, LPCWSTR windowname)
{ {
@@ -55,9 +49,6 @@ inline HWND FindWindow(LPCSTR classname, LPCSTR windowname)
#ifdef GetClassName #ifdef GetClassName
#undef GetClassName #undef GetClassName
#endif
#ifndef __WIN16__
#ifdef _UNICODE #ifdef _UNICODE
inline int GetClassName(HWND h, LPWSTR classname, int maxcount) inline int GetClassName(HWND h, LPWSTR classname, int maxcount)
{ {
@@ -75,9 +66,6 @@ inline int GetClassName(HWND h, LPSTR classname, int maxcount)
#ifdef GetClassInfo #ifdef GetClassInfo
#undef GetClassInfo #undef GetClassInfo
#endif
#ifndef __WIN16__
#ifdef _UNICODE #ifdef _UNICODE
inline BOOL GetClassInfo(HINSTANCE h, LPCWSTR name, LPWNDCLASSW winclass) inline BOOL GetClassInfo(HINSTANCE h, LPCWSTR name, LPWNDCLASSW winclass)
{ {
@@ -95,9 +83,6 @@ inline BOOL GetClassInfo(HINSTANCE h, LPCSTR name, LPWNDCLASSA winclass)
#ifdef LoadAccelerators #ifdef LoadAccelerators
#undef LoadAccelerators #undef LoadAccelerators
#endif
#ifndef __WIN16__
#ifdef _UNICODE #ifdef _UNICODE
inline HACCEL LoadAccelerators(HINSTANCE h, LPCWSTR name) inline HACCEL LoadAccelerators(HINSTANCE h, LPCWSTR name)
{ {
@@ -111,19 +96,10 @@ inline HACCEL LoadAccelerators(HINSTANCE h, LPCSTR name)
#endif #endif
#endif #endif
// GetWindowProc... this isn't a Windows API function?!?!
//ifdef GetWindowProc
// #undef GetWindowProc
//endif
// DrawText // DrawText
#ifdef DrawText #ifdef DrawText
#undef DrawText #undef DrawText
#endif
#ifndef __WIN16__
#ifdef _UNICODE #ifdef _UNICODE
inline int DrawText(HDC h, LPCWSTR str, int count, LPRECT rect, UINT format) inline int DrawText(HDC h, LPCWSTR str, int count, LPRECT rect, UINT format)
{ {
@@ -141,9 +117,6 @@ inline int DrawText(HDC h, LPCSTR str, int count, LPRECT rect, UINT format)
#ifdef StartDoc #ifdef StartDoc
#undef StartDoc #undef StartDoc
#endif
#ifndef __WIN16__
#ifdef _UNICODE #ifdef _UNICODE
inline int StartDoc(HDC h, CONST DOCINFOW* info) inline int StartDoc(HDC h, CONST DOCINFOW* info)
{ {
@@ -157,26 +130,10 @@ inline int StartDoc(HDC h, CONST DOCINFOA* info)
#endif #endif
#endif #endif
// GetFirstChild... not a Windows API Function!?!?!
//ifdef GetFirstChild
// #undef GetFirstChild
//endif
//ifdef GetNextChild
// #undef GetNextChild
//endif
//ifdef GetNextSibling
// #undef GetNextSibling
//endif
// GetObject // GetObject
#ifdef GetObject #ifdef GetObject
#undef GetObject #undef GetObject
#endif
#ifndef __WIN16__
inline int GetObject(HGDIOBJ h, int i, LPVOID buffer) inline int GetObject(HGDIOBJ h, int i, LPVOID buffer)
{ {
#ifdef _UNICODE #ifdef _UNICODE
@@ -187,4 +144,34 @@ inline int GetObject(HGDIOBJ h, int i, LPVOID buffer)
} }
#endif #endif
// For ming and cygwin
// GetFirstChild
#ifdef GetFirstChild
#undef GetFirstChild
inline HWND GetFirstChild(HWND h)
{
return GetTopWindow(h);
}
#endif
// GetNextSibling
#ifdef GetNextSibling
#undef GetNextSibling
inline HWND GetNextSibling(HWND h)
{
return GetWindow(h, GW_HWNDNEXT);
}
#endif
// GetWindowProc
//ifdef GetWindowProc
// #undef GetWindowProc
//endif
//ifdef GetNextChild
// #undef GetNextChild
//endif
#endif // _WX_WINUNDEF_H_ #endif // _WX_WINUNDEF_H_