X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/84882850e5e71939d541c1788b8446576a41ca30..c3be59bcdbc43ef1286cf5ea635d933bb802bd81:/src/os2/checklst.cpp diff --git a/src/os2/checklst.cpp b/src/os2/checklst.cpp index 45004b7486..3bb67b387b 100644 --- a/src/os2/checklst.cpp +++ b/src/os2/checklst.cpp @@ -272,7 +272,7 @@ wxCheckListBox::wxCheckListBox ( wxWindow* pParent, void wxCheckListBox::Delete( int n ) { - wxCHECK_RET( n >= 0 && n < m_nNumItems, + wxCHECK_RET( IsValid(n), wxT("invalid index in wxCheckListBox::Delete") ); wxListBox::Delete(n); @@ -408,7 +408,7 @@ void wxCheckListBox::OnLeftClick ( wxMouseEvent& rEvent ) size_t nItem = (size_t)(nY / vHeight); - if (nItem < (size_t)m_nNumItems) + if (nItem < m_nNumItems) GetItem(nItem)->Toggle(); // // else: it's not an error, just click outside of client zone