]> git.saurik.com Git - wxWidgets.git/commitdiff
delete now does remove the item in correct synch from m_datas and m_strings
authorStefan Csomor <csomor@advancedconcepts.ch>
Sat, 9 Jun 2001 09:11:45 +0000 (09:11 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Sat, 9 Jun 2001 09:11:45 +0000 (09:11 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10469 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/mac/carbon/choice.cpp
src/mac/choice.cpp

index e9a8357ea58d56d4d334ad1d3d5d4e1ef046734f..73dfa522d3df73fd958705feb647509e7e891c04 100644 (file)
@@ -91,7 +91,8 @@ void wxChoice::Delete(int n)
 
     ::DeleteMenuItem( m_macPopUpMenuHandle , n + 1) ;
     m_strings.Remove( n ) ;
-         SetControlMaximum( m_macControl , Number()) ;
+    m_datas.Remove( n ) ;
+       SetControlMaximum( m_macControl , Number()) ;
 }
 
 void wxChoice::Clear()
@@ -104,7 +105,7 @@ void wxChoice::Clear()
          }
     m_strings.Empty() ;
     m_datas.Empty() ;
-         SetControlMaximum( m_macControl , 0 ) ;
+       SetControlMaximum( m_macControl , 0 ) ;
 }
 
 void wxChoice::Free()
index e9a8357ea58d56d4d334ad1d3d5d4e1ef046734f..73dfa522d3df73fd958705feb647509e7e891c04 100644 (file)
@@ -91,7 +91,8 @@ void wxChoice::Delete(int n)
 
     ::DeleteMenuItem( m_macPopUpMenuHandle , n + 1) ;
     m_strings.Remove( n ) ;
-         SetControlMaximum( m_macControl , Number()) ;
+    m_datas.Remove( n ) ;
+       SetControlMaximum( m_macControl , Number()) ;
 }
 
 void wxChoice::Clear()
@@ -104,7 +105,7 @@ void wxChoice::Clear()
          }
     m_strings.Empty() ;
     m_datas.Empty() ;
-         SetControlMaximum( m_macControl , 0 ) ;
+       SetControlMaximum( m_macControl , 0 ) ;
 }
 
 void wxChoice::Free()