]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/carbon/listbox.cpp
memory leak fixed
[wxWidgets.git] / src / mac / carbon / listbox.cpp
index 9533882e9ece8773da4a2484f80eab8e37618381..3e5ae1bc372273992a28234a6f80fbe06bfe3fb7 100644 (file)
@@ -168,8 +168,8 @@ bool wxListBox::Create(wxWindow *parent, wxWindowID id,
     Size asize;
 
 
-    CreateListBoxControl( parent->MacGetRootWindow(), &bounds, false, 0, 1, false, true,
-                          kwxMacListItemHeight, kwxMacListItemHeight, false, &listDef, &m_macControl );
+    CreateListBoxControl( MAC_WXHWND(parent->MacGetRootWindow()), &bounds, false, 0, 1, false, true,
+                          kwxMacListItemHeight, kwxMacListItemHeight, false, &listDef, (ControlRef *)&m_macControl );
 
     GetControlData( (ControlHandle) m_macControl, kControlNoPart, kControlListBoxListHandleTag,
                    sizeof(ListHandle), (Ptr) &m_macList, &asize);
@@ -273,7 +273,7 @@ void  wxListBox::DoSetSize(int x, int y,
 #if TARGET_CARBON
     Rect bounds ;
     GetControlBounds( (ControlHandle) m_macControl , &bounds ) ;
-    ControlRef control = GetListVerticalScrollBar( m_macList ) ;
+    ControlRef control = GetListVerticalScrollBar( (ListHandle)m_macList ) ;
     if ( control )
     {
         Rect scrollbounds ;
@@ -737,7 +737,7 @@ void wxListBox::OnSize( const wxSizeEvent &event)
     Point pt;
 
 #if TARGET_CARBON
-    GetListCellSize(m_macList, &pt);
+    GetListCellSize((ListHandle)m_macList, &pt);
 #else
     pt = (**(ListHandle)m_macList).cellSize ;
 #endif