X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e9576ca53db96b462ed4c0b4bdf47d64c40203e4..5541d1fda4b73af86e42b2f43724f0c063a352d0:/src/mac/carbon/tabctrl.cpp?ds=inline diff --git a/src/mac/carbon/tabctrl.cpp b/src/mac/carbon/tabctrl.cpp index b3b45a72d1..db1992be6e 100644 --- a/src/mac/carbon/tabctrl.cpp +++ b/src/mac/carbon/tabctrl.cpp @@ -13,8 +13,11 @@ #pragma implementation "tabctrl.h" #endif +#include "wx/defs.h" + #include "wx/control.h" #include "wx/tabctrl.h" +#include "wx/mac/uma.h" #if !USE_SHARED_LIBRARY IMPLEMENT_DYNAMIC_CLASS(wxTabCtrl, wxControl) @@ -31,20 +34,18 @@ wxTabCtrl::wxTabCtrl() bool wxTabCtrl::Create(wxWindow *parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name) { - m_imageList = NULL; - - SetName(name); - - m_windowStyle = style; + Rect bounds ; + Str255 title ; - SetParent(parent); + m_imageList = NULL; + + MacPreControlCreate( parent , id , "" , pos , size ,style, wxDefaultValidator , name , &bounds , title ) ; - m_windowId = (id < 0 ? NewControlId() : id); - - if (parent) parent->AddChild(this); - - // TODO: create tab control - return FALSE; + m_macControl = ::NewControl( MAC_WXHWND(parent->MacGetRootWindow()) , &bounds , title , false , 0 , 0 , 1, + kControlTabSmallProc , (long) this ) ; + + MacPostControlCreate() ; + return TRUE ; } wxTabCtrl::~wxTabCtrl()