// wxListBase
// -----------------------------------------------------------------------------
-void wxListBase::Init(wxKeyType keyType = wxKEY_NONE)
+void wxListBase::Init(wxKeyType keyType)
{
m_nodeFirst =
m_nodeLast = (wxNodeBase *) NULL;
}
}
-// wxFAIL_MSG( "invalid index in wxListBase::Item" );
+ wxFAIL_MSG( "invalid index in wxListBase::Item" );
return (wxNodeBase *)NULL;
}
{
size_t N = GetCount();
char **array = new char *[N];
+ wxStringListNode *node;
size_t i = 0;
- for ( wxStringListNode *node = GetFirst(); node; node = node->GetNext() )
+ for ( node = GetFirst(); node; node = node->GetNext() )
{
array[i++] = node->GetData();
}
qsort (array, N, sizeof (char *), wx_comparestrings);
- Clear();
- for (i = 0; i < N; i++)
- Append (array[i]);
+ i = 0;
+ for ( node = GetFirst(); node; node = node->GetNext() )
+ node->SetData( array[i++] );
- delete[]array;
+ delete [] array;
}