]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/choice.cpp
renamed wxWave to wxSound; compatibility fixes
[wxWidgets.git] / src / mac / choice.cpp
index c963dcad3271faf238ae96a51b3ea303e50c752a..a18113dbf37d7c3651c8e431ac2aab0abc1af36d 100644 (file)
@@ -38,6 +38,20 @@ wxChoice::~wxChoice()
     // DisposeMenu( m_macPopUpMenuHandle ) ;
 }
 
     // DisposeMenu( m_macPopUpMenuHandle ) ;
 }
 
+bool wxChoice::Create(wxWindow *parent, wxWindowID id,
+           const wxPoint& pos,
+           const wxSize& size,
+           const wxArrayString& choices,
+           long style,
+           const wxValidator& validator,
+           const wxString& name)
+{
+    wxCArrayString chs(choices);
+
+    return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+                  style, validator, name);
+}
+
 bool wxChoice::Create(wxWindow *parent, wxWindowID id,
            const wxPoint& pos,
            const wxSize& size,
 bool wxChoice::Create(wxWindow *parent, wxWindowID id,
            const wxPoint& pos,
            const wxSize& size,
@@ -245,12 +259,11 @@ wxSize wxChoice::DoGetBestSize() const
 #endif
     {
         wxMacPortStateHelper st( UMAGetWindowPort( (WindowRef) MacGetRootWindow() ) ) ;
 #endif
     {
         wxMacPortStateHelper st( UMAGetWindowPort( (WindowRef) MacGetRootWindow() ) ) ;
-        wxFontRefData * font = (wxFontRefData*) m_font.GetRefData() ;
-        if ( font )
+        if ( m_font.Ok() )
         {
         {
-            ::TextFont( font->m_macFontNum ) ;
-            ::TextSize( short(font->m_macFontSize) ) ;
-            ::TextFace( font->m_macFontStyle ) ;
+            ::TextFont( m_font.GetMacFontNum() ) ;
+            ::TextSize( m_font.GetMacFontSize() ) ;
+            ::TextFace( m_font.GetMacFontStyle() ) ;
         }
         else
         {
         }
         else
         {