From 24ce4c1875bf69d896a16c82e879544d86f8c120 Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Fri, 29 Jun 2001 17:07:54 +0000 Subject: [PATCH] Some wxUniv compile fixes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10723 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/univ/frame.h | 8 ++++++++ include/wx/univ/setup.h | 3 ++- include/wx/univ/window.h | 8 ++++++++ src/generic/scrolwin.cpp | 2 ++ src/msw/window.cpp | 8 ++++---- 5 files changed, 24 insertions(+), 5 deletions(-) diff --git a/include/wx/univ/frame.h b/include/wx/univ/frame.h index 35a04ee61b..349462b295 100644 --- a/include/wx/univ/frame.h +++ b/include/wx/univ/frame.h @@ -20,6 +20,14 @@ // wxFrame // ---------------------------------------------------------------------------- +#if defined(__WXMSW__) +#define wxFrameNative wxFrameMSW +#elif defined(__WXGTK__) +#define wxFrameNative wxFrameGTK +#elif defined(__WXMGL__) +#define wxFrameNative wxFrameMGL +#endif + class wxFrame : public wxFrameNative { public: diff --git a/include/wx/univ/setup.h b/include/wx/univ/setup.h index 3b65f79709..0f893e3c75 100644 --- a/include/wx/univ/setup.h +++ b/include/wx/univ/setup.h @@ -38,7 +38,7 @@ #define wxUSE_TIMER 1 #define wxUSE_STOPWATCH 1 #define wxUSE_TIMEDATE 0 -#define wxUSE_DATETIME 0 +#define wxUSE_DATETIME 1 #define wxUSE_CONFIG 0 #define wxUSE_CONFIG_NATIVE 0 #define wxUSE_DIALUP_MANAGER 0 @@ -66,6 +66,7 @@ #define wxUSE_NOTEBOOK 1 #define wxUSE_FONTMAP 0 #define wxUSE_MIMETYPE 0 +#define wxUSE_IMAGE 1 #define wxUSE_CONTROLS 1 #define wxUSE_POPUPWIN 1 diff --git a/include/wx/univ/window.h b/include/wx/univ/window.h index 4af5b3fb22..ba2828e06f 100644 --- a/include/wx/univ/window.h +++ b/include/wx/univ/window.h @@ -55,6 +55,14 @@ enum // wxWindow // ---------------------------------------------------------------------------- +#if defined(__WXMSW__) +#define wxWindowNative wxWindowMSW +#elif defined(__WXGTK__) +#define wxWindowNative wxWindowGTK +#elif defined(__WXMGL__) +#define wxWindowNative wxWindowMGL +#endif + class WXDLLEXPORT wxWindow : public wxWindowNative { public: diff --git a/src/generic/scrolwin.cpp b/src/generic/scrolwin.cpp index 991029613d..e12edf05c9 100644 --- a/src/generic/scrolwin.cpp +++ b/src/generic/scrolwin.cpp @@ -242,7 +242,9 @@ wxScrollHelper::wxScrollHelper(wxWindow *win) m_scaleX = m_scaleY = 1.0; +#if wxUSE_MOUSEWHEEL m_wheelRotation = 0; +#endif m_win = m_targetWindow = (wxWindow *)NULL; diff --git a/src/msw/window.cpp b/src/msw/window.cpp index 91191899b5..316917aafb 100644 --- a/src/msw/window.cpp +++ b/src/msw/window.cpp @@ -2415,7 +2415,7 @@ long wxWindowMSW::MSWWindowProc(WXUINT message, WXWPARAM wParam, WXLPARAM lParam // Don't yet process menu help events, just windows if (info->iContextType == HELPINFO_WINDOW) { - wxWindow* subjectOfHelp = this; + wxWindowMSW* subjectOfHelp = this; bool eventProcessed = FALSE; while (subjectOfHelp && !eventProcessed) { @@ -3526,7 +3526,7 @@ bool wxWindowMSW::HandleCommand(WXWORD id, WXWORD cmd, WXHWND control) return GetEventHandler()->ProcessEvent(event); } -#if wxUSE_SPINCTRL +#if wxUSE_SPINCTRL && !defined(__WXUNIVERSAL__) else { // the text ctrl which is logically part of wxSpinCtrl sends WM_COMMAND @@ -3651,7 +3651,7 @@ bool wxWindowMSW::HandleMouseMove(int x, int y, WXUINT flags) } -bool wxWindow::HandleMouseWheel(WXWPARAM wParam, WXLPARAM lParam) +bool wxWindowMSW::HandleMouseWheel(WXWPARAM wParam, WXLPARAM lParam) { #if wxUSE_MOUSEWHEEL wxMouseEvent event(wxEVT_MOUSEWHEEL); @@ -4224,7 +4224,7 @@ extern wxWindow *wxGetWindowFromHWND(WXHWND hWnd) // spin control text buddy window should be mapped to spin ctrl // itself so try it too -#if wxUSE_SPINCTRL +#if wxUSE_SPINCTRL && !defined(__WXUNIVERSAL__) if ( !win ) { win = wxSpinCtrl::GetSpinForTextCtrl((WXHWND)hwnd); -- 2.45.2