X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/36eca861601eb5329d7b87bc6e93cc31c49584f9..3eef425f9a7387d771c1539bdf5e3f02060eb334:/src/osx/cocoa/bmpbuttn.mm diff --git a/src/osx/cocoa/bmpbuttn.mm b/src/osx/cocoa/bmpbuttn.mm index 3de4eafe5f..0c1f471a3e 100644 --- a/src/osx/cocoa/bmpbuttn.mm +++ b/src/osx/cocoa/bmpbuttn.mm @@ -31,15 +31,12 @@ wxWidgetImplType* wxWidgetImpl::CreateBitmapButton( wxWindowMac* wxpeer, long style, long extraStyle) { - NSView* sv = static_cast(wxpeer->GetParent()->GetHandle() ); - NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ; wxNSButton* v = [[wxNSButton alloc] initWithFrame:r]; [v setBezelStyle:NSRegularSquareBezelStyle]; [v setImage:bitmap.GetNSImage() ]; [v setButtonType:NSMomentaryPushInButton]; - [sv addSubview:v]; wxWidgetCocoaImpl* c = new wxWidgetCocoaImpl( wxpeer, v ); [v setImplementation:c]; return c;