X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/da0634c1401743089b1d8be20f9b6bdad0e8085b..f9007c324c9b4f6288156dcf0b865090ee0c0c38:/src/cocoa/radiobox.mm diff --git a/src/cocoa/radiobox.mm b/src/cocoa/radiobox.mm index 71b8994bad..397829a6fd 100644 --- a/src/cocoa/radiobox.mm +++ b/src/cocoa/radiobox.mm @@ -12,6 +12,8 @@ #include "wx/app.h" #include "wx/radiobox.h" +#import + IMPLEMENT_DYNAMIC_CLASS(wxRadioBox, wxControl) BEGIN_EVENT_TABLE(wxRadioBox, wxControl) END_EVENT_TABLE() @@ -28,7 +30,8 @@ bool wxRadioBox::Create(wxWindow *parent, wxWindowID winid, { if(!CreateControl(parent,winid,pos,size,style,validator,name)) return false; - m_cocoaNSView = NULL; + SetNSView([[NSView alloc] initWithFrame: NSMakeRect(10,10,20,20)]); + [m_cocoaNSView release]; if(m_parent) m_parent->CocoaAddChild(this); return true; @@ -37,6 +40,7 @@ bool wxRadioBox::Create(wxWindow *parent, wxWindowID winid, wxRadioBox::~wxRadioBox() { CocoaRemoveFromParent(); + SetNSView(NULL); } // selection