WXDLLEXPORT_DATA(extern const char*) wxRadioBoxNameStr;
// List box item
-class WXDLLEXPORT wxBitmap ;
+class wxBitmap ;
-class WXDLLEXPORT wxRadioButton ;
+class wxRadioButton ;
-class WXDLLEXPORT wxRadioBox: public wxControl
+class wxRadioBox: public wxControl
{
DECLARE_DYNAMIC_CLASS(wxRadioBox)
public:
const wxValidator& val = wxDefaultValidator, const wxString& name = wxRadioBoxNameStr);
// Specific functions (in wxWindows2 reference)
- void Enable(bool enable);
+ bool Enable(bool enable);
void Enable(int item, bool enable);
int FindString(const wxString& s) const;
wxString GetLabel() const;
//-------------------------------------------------------------------------------------
// 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);
}
//-------------------------------------------------------------------------------------
i++;
current=current->NextInCycle();
}
- return current->Enable(enable);
}
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
//-------------------------------------------------------------------------------------
// 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);
}
//-------------------------------------------------------------------------------------
i++;
current=current->NextInCycle();
}
- return current->Enable(enable);
}
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