X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/36eca861601eb5329d7b87bc6e93cc31c49584f9..bc5c09a3aa3662137da2d781c0b101a598d2650d:/src/osx/cocoa/bmpbuttn.mm diff --git a/src/osx/cocoa/bmpbuttn.mm b/src/osx/cocoa/bmpbuttn.mm index 3de4eafe5f..bc9a26325d 100644 --- a/src/osx/cocoa/bmpbuttn.mm +++ b/src/osx/cocoa/bmpbuttn.mm @@ -9,40 +9,4 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#include "wx/wxprec.h" - -#if wxUSE_BMPBUTTON - -#include "wx/bmpbuttn.h" -#include "wx/image.h" - -#ifndef WX_PRECOMP - #include "wx/dcmemory.h" -#endif - -#include "wx/osx/private.h" - -wxWidgetImplType* wxWidgetImpl::CreateBitmapButton( wxWindowMac* wxpeer, - wxWindowMac* parent, - wxWindowID id, - const wxBitmap& bitmap, - const wxPoint& pos, - const wxSize& size, - 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; -} - -#endif +// everything is done in button.mm now \ No newline at end of file