diff options
author | Thiago Macieira <thiago.macieira@intel.com> | 2012-05-02 16:32:26 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-05-03 06:10:20 +0200 |
commit | 1eac22a1b9dad7f843916afa9b7c820aa1c23777 (patch) | |
tree | 4a109a87d3bd7c560e6e40efd7ff15678a8dd0a0 /tests/auto/widgets/dialogs | |
parent | 425b925b7e9dd818f2a58fd7bc77bfe8475e6483 (diff) |
Change remaining uses of {to,from}Ascii to {to,from}Latin1 [QtWidgets]
This operation should be a no-op anyway, since at this point in time,
the fromAscii and toAscii functions simply call their fromLatin1 and
toLatin1 counterparts.
Task-number: QTBUG-21872
Change-Id: Ie8ac500f2f8ebe99b7525feaa7b39247e641a461
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Diffstat (limited to 'tests/auto/widgets/dialogs')
3 files changed, 5 insertions, 5 deletions
diff --git a/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp b/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp index e8fc5ad603..a62c1a8f9a 100644 --- a/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp +++ b/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp @@ -504,7 +504,7 @@ void tst_QFiledialog::completer() // press 'keys' for the input for (int i = 0; i < input.count(); ++i) - QTest::keyPress(lineEdit, input[i].toAscii()); + QTest::keyPress(lineEdit, input[i].toLatin1()); QStringList expectedFiles; if (expected == -1) { diff --git a/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp b/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp index 4a6f714a7c..d90c6f8851 100644 --- a/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp +++ b/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp @@ -568,7 +568,7 @@ void tst_QFileDialog2::completionOnLevelAfterRoot() // - No another dir with same start QString testDir; foreach (const QString &entry, entryList) { - if (entry.size() > 5 && QString(entry.toAscii()).compare(entry) == 0) { + if (entry.size() > 5 && QString(entry.toLatin1()).compare(entry) == 0) { bool invalid = false; for (int i = 0; i < 5; i++) { if (!entry.at(i).isLetter()) { @@ -605,7 +605,7 @@ void tst_QFileDialog2::completionOnLevelAfterRoot() #if defined(Q_OS_WIN) && !defined(Q_OS_WINCE) //I love testlib :D for (int i = 0; i < 5; i++) - QTest::keyClick(edit, testDir.at(i).toLower().toAscii() - 'a' + Qt::Key_A); + QTest::keyClick(edit, testDir.at(i).toLower().toLatin1() - 'a' + Qt::Key_A); #else QTest::keyClick(edit, Qt::Key_E); QTest::keyClick(edit, Qt::Key_T); diff --git a/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp b/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp index a38c2d070d..f6c10bc2e9 100644 --- a/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp +++ b/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp @@ -110,7 +110,7 @@ void testTypingValue( sbox->selectAll(); for (int i = 0; i < value.size(); ++i) { const QChar valChar = value[i]; - _keyClick(static_cast<QWidget *>(sbox), valChar.toAscii()); // ### always guaranteed to work? + _keyClick(static_cast<QWidget *>(sbox), valChar.toLatin1()); // ### always guaranteed to work? if (sbox->hasAcceptableInput()) QVERIFY(okButton->isEnabled()); else @@ -123,7 +123,7 @@ void testTypingValue(QLineEdit *ledit, QPushButton *okButton, const QString &val ledit->selectAll(); for (int i = 0; i < value.size(); ++i) { const QChar valChar = value[i]; - _keyClick(ledit, valChar.toAscii()); // ### always guaranteed to work? + _keyClick(ledit, valChar.toLatin1()); // ### always guaranteed to work? QVERIFY(ledit->hasAcceptableInput()); QVERIFY(okButton->isEnabled()); } |