Fix harmless signed/unsigned comparison warning in a test.
Don't compare int with unsigned to avoid warnings that were introduced by the changes of r75940. See #15980. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76058 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -528,24 +528,27 @@ void TextCtrlTestCase::LongText()
|
|||||||
delete m_text;
|
delete m_text;
|
||||||
CreateText(wxTE_MULTILINE|wxTE_DONTWRAP);
|
CreateText(wxTE_MULTILINE|wxTE_DONTWRAP);
|
||||||
|
|
||||||
|
const int numLines = 1000;
|
||||||
|
const int lenPattern = 100;
|
||||||
|
int i;
|
||||||
|
|
||||||
// Pattern for the line.
|
// Pattern for the line.
|
||||||
wxChar linePattern[100+1];
|
wxChar linePattern[lenPattern+1];
|
||||||
for (int i = 0; i < WXSIZEOF(linePattern) - 1; i++)
|
for (i = 0; i < lenPattern - 1; i++)
|
||||||
{
|
{
|
||||||
linePattern[i] = wxChar('0' + i % 10);
|
linePattern[i] = wxChar('0' + i % 10);
|
||||||
}
|
}
|
||||||
linePattern[WXSIZEOF(linePattern) - 1] = wxChar('\0');
|
linePattern[WXSIZEOF(linePattern) - 1] = wxChar('\0');
|
||||||
|
|
||||||
// Fill the control.
|
// Fill the control.
|
||||||
const int numLines = 1000;
|
|
||||||
m_text->SetMaxLength(15000);
|
m_text->SetMaxLength(15000);
|
||||||
for (int i = 0; i < numLines; i++)
|
for (i = 0; i < numLines; i++)
|
||||||
{
|
{
|
||||||
m_text->AppendText(wxString::Format(wxT("[%3d] %s\n"), i, linePattern));
|
m_text->AppendText(wxString::Format(wxT("[%3d] %s\n"), i, linePattern));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check the content.
|
// Check the content.
|
||||||
for (int i = 0; i < numLines; i++)
|
for (i = 0; i < numLines; i++)
|
||||||
{
|
{
|
||||||
wxString pattern = wxString::Format(wxT("[%3d] %s"), i, linePattern);
|
wxString pattern = wxString::Format(wxT("[%3d] %s"), i, linePattern);
|
||||||
wxString line = m_text->GetLineText(i);
|
wxString line = m_text->GetLineText(i);
|
||||||
|
Reference in New Issue
Block a user