// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
-#if !USE_SHARED_LIBRARY
- IMPLEMENT_DYNAMIC_CLASS(wxSpinButton, wxControl)
- IMPLEMENT_DYNAMIC_CLASS(wxSpinEvent, wxScrollEvent)
-#endif
-
-extern ControlActionUPP wxMacLiveScrollbarActionUPP ;
+IMPLEMENT_DYNAMIC_CLASS(wxSpinButton, wxControl)
+IMPLEMENT_DYNAMIC_CLASS(wxSpinEvent, wxScrollEvent)
bool wxSpinButton::Create(wxWindow *parent, wxWindowID id, const wxPoint& pos, const wxSize& size,
long style, const wxString& name)
{
bool wxSpinButton::Create(wxWindow *parent, wxWindowID id, const wxPoint& pos, const wxSize& size,
long style, const wxString& name)
{
if ( !wxSpinButtonBase::Create(parent, id, pos, size,
style, wxDefaultValidator, name) )
return false;
m_min = 0;
m_max = 100;
if ( !wxSpinButtonBase::Create(parent, id, pos, size,
style, wxDefaultValidator, name) )
return false;
m_min = 0;
m_max = 100;
verify_noerr ( CreateLittleArrowsControl( MAC_WXHWND(parent->MacGetTopLevelWindowRef()) , &bounds , 0 , m_min , m_max , 1 ,
m_peer->GetControlRefAddr() ) );
verify_noerr ( CreateLittleArrowsControl( MAC_WXHWND(parent->MacGetTopLevelWindowRef()) , &bounds , 0 , m_min , m_max , 1 ,
m_peer->GetControlRefAddr() ) );
if ( m_value - oldValue == -1 )
scrollEvent = wxEVT_SCROLL_LINEDOWN ;
else if ( m_value - oldValue == 1 )
scrollEvent = wxEVT_SCROLL_LINEUP ;
else
scrollEvent = wxEVT_SCROLL_THUMBTRACK ;
if ( m_value - oldValue == -1 )
scrollEvent = wxEVT_SCROLL_LINEDOWN ;
else if ( m_value - oldValue == 1 )
scrollEvent = wxEVT_SCROLL_LINEUP ;
else
scrollEvent = wxEVT_SCROLL_THUMBTRACK ;
event.SetPosition(m_value);
event.SetEventObject( this );
if ((GetEventHandler()->ProcessEvent( event )) &&
event.SetPosition(m_value);
event.SetEventObject( this );
if ((GetEventHandler()->ProcessEvent( event )) &&
-void wxSpinButton::MacHandleControlClick( WXWidget control , wxInt16 controlpart , bool mouseStillDown )
+void wxSpinButton::MacHandleControlClick( WXWidget control , wxInt16 controlpart , bool mouseStillDown )
{
/*
// these have been handled by the live action proc already
int nScrollInc = 0;
wxMacCarbonEvent cEvent( (EventRef) event ) ;
{
/*
// these have been handled by the live action proc already
int nScrollInc = 0;
wxMacCarbonEvent cEvent( (EventRef) event ) ;
switch( cEvent.GetParameter<ControlPartCode>(kEventParamControlPart,typeControlPartCode) )
{
case kControlUpButtonPart :
switch( cEvent.GetParameter<ControlPartCode>(kEventParamControlPart,typeControlPartCode) )
{
case kControlUpButtonPart :