X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/786a9df157da9927537feae65f72c6435f6d1a4d..589abe2cdb7ce83a8c4f3c8785137974f8c3d30f:/src/mac/carbon/slider.cpp diff --git a/src/mac/carbon/slider.cpp b/src/mac/carbon/slider.cpp index a46467044f..287bfe78ab 100644 --- a/src/mac/carbon/slider.cpp +++ b/src/mac/carbon/slider.cpp @@ -22,7 +22,6 @@ BEGIN_EVENT_TABLE(wxSlider, wxControl) END_EVENT_TABLE() // The dimensions of the different styles of sliders (from Aqua document) -#define wxSLIDER_DIMENSIONACROSS 15 #define wxSLIDER_DIMENSIONACROSS_WITHTICKMARKS 24 #define wxSLIDER_DIMENSIONACROSS_ARROW 18 @@ -346,9 +345,15 @@ void wxSlider::DoSetSizeHints( int minW, int minH, wxSize size = GetBestSize(); if (GetWindowStyle() & wxSL_VERTICAL) - wxWindow::DoSetSizeHints(size.x, minH, size.x, maxH, incW, incH); + { + SetMinSize( wxSize(size.x,minH) ); + SetMaxSize( wxSize(size.x,maxH) ); + } else - wxWindow::DoSetSizeHints(minW, size.y, maxW, size.y, incW, incH); + { + SetMinSize( wxSize(minW,size.y) ); + SetMaxSize( wxSize(maxW,size.y) ); + } } wxSize wxSlider::DoGetBestSize() const @@ -416,13 +421,11 @@ wxSize wxSlider::DoGetBestSize() const void wxSlider::DoSetSize(int x, int y, int w, int h, int sizeFlags) { - int xborder, yborder; + int yborder = 0; int minValWidth, maxValWidth, textheight; int sliderBreadth; int width = w; - xborder = yborder = 0; - if (GetWindowStyle() & wxSL_LABELS) { wxString text;