void wxSpinButton::SetValue(int val)
{
- MacHandleValueChanged( val - m_value ) ;
+ m_value = val ;
}
void wxSpinButton::SetRange(int minVal, int maxVal)
{
m_min = minVal;
m_max = maxVal;
- SetControlMaximum( (ControlHandle) m_macControl , maxVal ) ;
- SetControlMinimum((ControlHandle) m_macControl , minVal ) ;
+ SetControl32BitMaximum( (ControlHandle) m_macControl , maxVal ) ;
+ SetControl32BitMinimum((ControlHandle) m_macControl , minVal ) ;
}
void wxSpinButton::MacHandleValueChanged( int inc )
m_value = m_max;
}
- if ( oldValue - m_value == -1 )
+ if ( m_value - oldValue == -1 )
scrollEvent = wxEVT_SCROLL_LINEDOWN ;
- else if ( oldValue - m_value == 1 )
+ else if ( m_value - oldValue == 1 )
scrollEvent = wxEVT_SCROLL_LINEUP ;
else
scrollEvent = wxEVT_SCROLL_THUMBTRACK ;
{
m_value = oldValue ;
}
- SetControlValue( (ControlHandle) m_macControl , m_value ) ;
+ SetControl32BitValue( (ControlHandle) m_macControl , m_value ) ;
/* always send a thumbtrack event */
if (scrollEvent != wxEVT_SCROLL_THUMBTRACK)