Change QtSql documentation to recommend QString::toUtf8
Change-Id: I604166677ea182553adffc4835050f2964f2aef9 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>bb10
parent
0c2d643e01
commit
afbdf3b1cc
|
|
@ -202,8 +202,8 @@ void QSqlQuery_snippets()
|
|||
QMapIterator<QString, QVariant> i(query.boundValues());
|
||||
while (i.hasNext()) {
|
||||
i.next();
|
||||
cout << i.key().toAscii().data() << ": "
|
||||
<< i.value().toString().toAscii().data() << endl;
|
||||
cout << i.key().toUtf8().data() << ": "
|
||||
<< i.value().toString().toUtf8().data() << endl;
|
||||
}
|
||||
//! [14]
|
||||
}
|
||||
|
|
@ -213,7 +213,7 @@ void QSqlQuery_snippets()
|
|||
//! [15]
|
||||
QList<QVariant> list = query.boundValues().values();
|
||||
for (int i = 0; i < list.size(); ++i)
|
||||
cout << i << ": " << list.at(i).toString().toAscii().data() << endl;
|
||||
cout << i << ": " << list.at(i).toString().toUtf8().data() << endl;
|
||||
//! [15]
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue