X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/327788acc5e4915df4e9e97db7fb08a4c4a00cdd..f009156727ddfbca08197b63d0fbee00df4078f5:/src/mac/carbon/spinctrl.cpp diff --git a/src/mac/carbon/spinctrl.cpp b/src/mac/carbon/spinctrl.cpp index a083c8a3c5..22553d47f1 100644 --- a/src/mac/carbon/spinctrl.cpp +++ b/src/mac/carbon/spinctrl.cpp @@ -319,4 +319,15 @@ void wxSpinCtrl::SetRange(int min, int max) m_btn->SetRange(min, max); } +void wxSpinCtrl::SetSelection(long from, long to) +{ + // if from and to are both -1, it means (in wxWindows) that all text should + // be selected + if ( (from == -1) && (to == -1) ) + { + from = 0; + } + m_text->SetSelection(from, to); +} + #endif // wxUSE_SPINCTRL