Commit 852a2d40 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Port some Q_FOREACH

parent deae9bbf
......@@ -94,7 +94,8 @@ void MailWidget::setMail(const KContacts::Email &email)
if (value.contains(QStringLiteral("PREF"))) {
setPreferred(true);
}
Q_FOREACH (const QString &type, mMailType->selectTypeList()) {
const QStringList lst = mMailType->selectTypeList();
for (const QString &type : lst) {
if (value.contains(type)) {
mOldType = type;
mMailType->setCurrentIndex(mMailType->findData(type));
......
......@@ -147,7 +147,8 @@ void WebWidget::loadWebSite(const KContacts::ResourceLocatorUrl &url)
if (value.contains(QStringLiteral("PREF"))) {
setPreferred(true);
}
Q_FOREACH (const QString &type, mWebType->selectTypeList()) {
const QStringList lst = mWebType->selectTypeList();
for (const QString &type : lst) {
if (value.contains(type)) {
mOldType = type;
mWebType->setCurrentIndex(mWebType->findData(type));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment