X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/1395ff56f4a8dd0fa400abc0faecc281c304caf7..5ebdc86afc95a60fbeb0b2a71c38dd26c8a1b0b4:/src/mac/radiobox.cpp

diff --git a/src/mac/radiobox.cpp b/src/mac/radiobox.cpp
index d00911c8fd..70da0df49c 100644
--- a/src/mac/radiobox.cpp
+++ b/src/mac/radiobox.cpp
@@ -20,9 +20,7 @@
 #include "wx/radiobox.h"
 #include <wx/mac/uma.h>
 
-#if !USE_SHARED_LIBRARY
 IMPLEMENT_DYNAMIC_CLASS(wxRadioBox, wxControl)
-#endif
 
 #pragma mark -
 #pragma mark ### Constructors & destructor ###
@@ -123,18 +121,20 @@ bool wxRadioBox::Create(wxWindow *parent, wxWindowID id, const wxString& label,
 //-------------------------------------------------------------------------------------
 // Enables or disables the entire radiobox
 
-void wxRadioBox::Enable(bool enable)
+bool wxRadioBox::Enable(bool enable)
 {
    	int i;
     wxRadioButton *current;
     
-    wxControl::Enable(enable);
+    if (!wxControl::Enable(enable))
+    	return (false);
 
     current=m_radioButtonCycle;
    	for (i=0;i<m_noItems;i++) {
     	current->Enable(enable);
     	current=current->NextInCycle();
     	}
+    return (true);
 }
 
 //-------------------------------------------------------------------------------------
@@ -155,7 +155,6 @@ void wxRadioBox::Enable(int item, bool enable)
     	i++;
     	current=current->NextInCycle();
     	}
-    return current->Enable(enable);
 }
 
 
@@ -464,7 +463,7 @@ void wxRadioBox::DoSetSize(int x, int y, int width, int height, int sizeFlags)
 	totHeight = GetNumVer() * (maxHeight + charHeight/2) + charHeight*3/2;
 	totWidth  = GetNumHor() * (maxWidth + charWidth) + charWidth;
 
-	wxControl::DoSetSize(x_offset,y_offset,totWidth,totHeight);
+	wxControl::DoSetSize(x_offset,y_offset,totWidth,totHeight,wxSIZE_AUTO);
 
 // arrange radiobuttons