Switch to wxCHECK so the bad code isn't still executed if the assert
dialog is ignored. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@22811 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -3138,7 +3138,8 @@ int wxGridStringTable::GetNumberCols()
|
|||||||
|
|
||||||
wxString wxGridStringTable::GetValue( int row, int col )
|
wxString wxGridStringTable::GetValue( int row, int col )
|
||||||
{
|
{
|
||||||
wxASSERT_MSG( (row < GetNumberRows()) && (col < GetNumberCols()),
|
wxCHECK_MSG( (row < GetNumberRows()) && (col < GetNumberCols()),
|
||||||
|
wxEmptyString,
|
||||||
_T("invalid row or column index in wxGridStringTable") );
|
_T("invalid row or column index in wxGridStringTable") );
|
||||||
|
|
||||||
return m_data[row][col];
|
return m_data[row][col];
|
||||||
@@ -3146,7 +3147,7 @@ wxString wxGridStringTable::GetValue( int row, int col )
|
|||||||
|
|
||||||
void wxGridStringTable::SetValue( int row, int col, const wxString& value )
|
void wxGridStringTable::SetValue( int row, int col, const wxString& value )
|
||||||
{
|
{
|
||||||
wxASSERT_MSG( (row < GetNumberRows()) && (col < GetNumberCols()),
|
wxCHECK_RET( (row < GetNumberRows()) && (col < GetNumberCols()),
|
||||||
_T("invalid row or column index in wxGridStringTable") );
|
_T("invalid row or column index in wxGridStringTable") );
|
||||||
|
|
||||||
m_data[row][col] = value;
|
m_data[row][col] = value;
|
||||||
@@ -3154,7 +3155,8 @@ void wxGridStringTable::SetValue( int row, int col, const wxString& value )
|
|||||||
|
|
||||||
bool wxGridStringTable::IsEmptyCell( int row, int col )
|
bool wxGridStringTable::IsEmptyCell( int row, int col )
|
||||||
{
|
{
|
||||||
wxASSERT_MSG( (row < GetNumberRows()) && (col < GetNumberCols()),
|
wxCHECK_MSG( (row < GetNumberRows()) && (col < GetNumberCols()),
|
||||||
|
true,
|
||||||
_T("invalid row or column index in wxGridStringTable") );
|
_T("invalid row or column index in wxGridStringTable") );
|
||||||
|
|
||||||
return (m_data[row][col] == wxEmptyString);
|
return (m_data[row][col] == wxEmptyString);
|
||||||
|
Reference in New Issue
Block a user