-int wxChoice::FindString(
- const wxString& rsStr
-) const
-{
- int nPos;
- int nTextLength;
- PSZ zStr;
- int nItemCount;
-
- nItemCount = (int)LONGFROMMR(::WinSendMsg(GetHwnd(), LM_QUERYITEMCOUNT, (MPARAM)0, (MPARAM)0));
- for (nPos = 0; nPos < nItemCount; nPos++)
- {
- nTextLength = (int)LONGFROMMR(::WinSendMsg(GetHwnd(), LM_QUERYITEMTEXTLENGTH, (MPARAM)nPos, (MPARAM)0));
- zStr = new char[nTextLength + 1];
- ::WinSendMsg(GetHwnd(), LM_QUERYITEMTEXT, MPFROM2SHORT((SHORT)nPos, (SHORT)nTextLength), (MPARAM)zStr);
- if (rsStr == (wxChar*)zStr)
- {
- delete [] zStr;
- break;
- }
- delete [] zStr;
- }
- return nPos;
-} // end of wxChoice::FindString
-
-void wxChoice::SetString(
- int n
-, const wxString& rsStr
-)