]> git.saurik.com Git - wxWidgets.git/commitdiff
minValue and maxValue are interpreted correctly in SetRange() (were inversed)
authorVadim Zeitlin <vadim@wxwidgets.org>
Thu, 10 Dec 1998 21:50:44 +0000 (21:50 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Thu, 10 Dec 1998 21:50:44 +0000 (21:50 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1164 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/spinbutt.cpp

index 89680b5f5e15a4560f294491b56bd39a96f5a392..4f8c5e5b760864e658621fe84303917d35e33962 100644 (file)
@@ -91,7 +91,7 @@ bool wxSpinButton::Create(wxWindow *parent, wxWindowID id, const wxPoint& pos, c
     m_windowId,
     wxGetInstance(),
     0,
-       m_min, m_max, 0);
+       m_min, m_max, m_min);
 
   m_hWnd = (WXHWND) hWndListControl;
   if (parent) parent->AddChild(this);
@@ -126,7 +126,8 @@ void wxSpinButton::SetRange(int minVal, int maxVal)
 {
        m_min = minVal;
        m_max = maxVal;
-       ::SendMessage((HWND) GetHWND(), UDM_SETRANGE, 0, (LPARAM) MAKELONG((short) minVal, (short) maxVal));
+       ::SendMessage((HWND) GetHWND(), UDM_SETRANGE, 0,
+                   (LPARAM) MAKELONG((short)maxVal, (short)minVal));
 }
 
 void wxSpinButton::MSWOnVScroll(WXWORD wParam, WXWORD pos, WXHWND control)