X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fdaf613add176525ed8b6cafaf278dfd80f85074..fe08e597048268b58f76f240e3f3dff52cdd6ffe:/src/mac/carbon/scrolbar.cpp diff --git a/src/mac/carbon/scrolbar.cpp b/src/mac/carbon/scrolbar.cpp index 0c1a130c78..e9d45ce4e5 100644 --- a/src/mac/carbon/scrolbar.cpp +++ b/src/mac/carbon/scrolbar.cpp @@ -13,6 +13,8 @@ #pragma implementation "scrolbar.h" #endif +#include "wx/defs.h" + #include "wx/scrolbar.h" #include "wx/mac/uma.h" @@ -41,7 +43,7 @@ bool wxScrollBar::Create(wxWindow *parent, wxWindowID id, MacPreControlCreate( parent , id , "" , pos , size ,style, validator , name , &bounds , title ) ; - m_macControl = UMANewControl( parent->GetMacRootWindow() , &bounds , title , false , 0 , 0 , 100, + m_macControl = UMANewControl( parent->GetMacRootWindow() , &bounds , title , true , 0 , 0 , 100, kControlScrollBarLiveProc , (long) this ) ; wxASSERT_MSG( m_macControl != NULL , "No valid mac control" ) ; @@ -112,19 +114,19 @@ void wxScrollBar::MacHandleControlClick( ControlHandle control , SInt16 controlp switch( controlpart ) { case kControlUpButtonPart : - nScrollInc = -1; + nScrollInc = -m_pageSize; scrollEvent = wxEVT_SCROLL_LINEUP; break ; case kControlDownButtonPart : - nScrollInc = 1; + nScrollInc = m_pageSize; scrollEvent = wxEVT_SCROLL_LINEDOWN; break ; case kControlPageUpPart : - nScrollInc = -m_pageSize; + nScrollInc = -m_viewSize; scrollEvent = wxEVT_SCROLL_PAGEUP; break ; case kControlPageDownPart : - nScrollInc = m_pageSize; + nScrollInc = m_viewSize; scrollEvent = wxEVT_SCROLL_PAGEDOWN; break ; case kControlIndicatorPart :