From ffcb4ee424061633cedc1c0ba6c04180d5048da9 Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Mon, 25 Aug 2003 14:15:20 +0000 Subject: [PATCH] WinCE fixes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23200 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/msw/winundef.h | 2 +- src/common/dynlib.cpp | 4 ++++ src/msw/toplevel.cpp | 6 ++++++ src/msw/utils.cpp | 2 +- src/msw/wince/tbarwce.cpp | 2 +- 5 files changed, 13 insertions(+), 3 deletions(-) diff --git a/include/wx/msw/winundef.h b/include/wx/msw/winundef.h index 41181e982a..01dad4ad0d 100644 --- a/include/wx/msw/winundef.h +++ b/include/wx/msw/winundef.h @@ -27,8 +27,8 @@ // CreateDialog -//#ifdef(CreateDialog) #if !defined(__WXWINCE__) && defined(CreateDialog) +// #if defined(CreateDialog) #undef CreateDialog inline HWND CreateDialog(HINSTANCE hInstance, diff --git a/src/common/dynlib.cpp b/src/common/dynlib.cpp index c7e7a28ed9..ab4178d9a0 100644 --- a/src/common/dynlib.cpp +++ b/src/common/dynlib.cpp @@ -353,7 +353,11 @@ void *wxDynamicLibrary::GetSymbol(const wxString &name, bool *success) const symbol = 0; #elif defined(__WINDOWS__) +#ifdef __WXWINCE__ + symbol = (void*) ::GetProcAddress( m_handle, name ); +#else symbol = (void*) ::GetProcAddress( m_handle, name.mb_str() ); +#endif #else #error "runtime shared lib support not implemented" diff --git a/src/msw/toplevel.cpp b/src/msw/toplevel.cpp index 7772899d1b..76363e5dc7 100644 --- a/src/msw/toplevel.cpp +++ b/src/msw/toplevel.cpp @@ -43,6 +43,12 @@ #include "wx/msw/private.h" #include "wx/msw/winundef.h" +// This can't be undefed in winundef.h or +// there are further errors +#if defined(__WXWINCE__) && defined(CreateDialog) +#undef CreateDialog +#endif + #include "wx/display.h" #ifndef ICON_BIG diff --git a/src/msw/utils.cpp b/src/msw/utils.cpp index fae0cb322d..e3de12da51 100644 --- a/src/msw/utils.cpp +++ b/src/msw/utils.cpp @@ -144,7 +144,7 @@ bool wxGetHostName(wxChar *buf, int maxSize) // get full hostname (with domain name if possible) bool wxGetFullHostName(wxChar *buf, int maxSize) { -#ifndef __WXMICROWIN__ +#if !defined( __WXMICROWIN__) && wxUSE_DYNAMIC_LOADER // TODO should use GetComputerNameEx() when available // we don't want to always link with Winsock DLL as we might not use it at diff --git a/src/msw/wince/tbarwce.cpp b/src/msw/wince/tbarwce.cpp index 22cd6ffe97..491006ad37 100644 --- a/src/msw/wince/tbarwce.cpp +++ b/src/msw/wince/tbarwce.cpp @@ -121,7 +121,7 @@ // wxWin macros // ---------------------------------------------------------------------------- -IMPLEMENT_DYNAMIC_CLASS(wxToolBar, wxToolBarBase) +IMPLEMENT_DYNAMIC_CLASS(wxToolBar, wxControl) BEGIN_EVENT_TABLE(wxToolBar, wxToolBarBase) EVT_MOUSE_EVENTS(wxToolBar::OnMouseEvent) -- 2.45.2