Commit 43e88fbb authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Modernize code

parent eac7e8f9
Pipeline #60345 passed with stage
in 52 minutes and 47 seconds
......@@ -26,11 +26,11 @@
#include <QPushButton>
#include <QStyledItemDelegate>
typedef struct {
using TemplateInfo = struct {
QString displayName;
QString fileName;
bool isDeletable = false;
} TemplateInfo;
};
class TemplatesModel : public QAbstractTableModel
{
......
......@@ -202,7 +202,7 @@ void GMXImportExportPluginInterface::doExport(QFile *fp, const KContacts::Addres
QTextStream t(fp);
t.setCodec("ISO 8859-1");
typedef QMap<int, const KContacts::Addressee *> AddresseeMap;
using AddresseeMap = QMap<int, const KContacts::Addressee *>;
AddresseeMap addresseeMap;
const KContacts::Addressee *addressee = nullptr;
......@@ -447,7 +447,7 @@ void GMXImportExportPluginInterface::importGMX()
QStringList itemList;
QMap<QString, QString> categoriesOfAddressee;
typedef QMap<QString, KContacts::Addressee *> AddresseeMap;
using AddresseeMap = QMap<QString, KContacts::Addressee *>;
AddresseeMap addresseeMap;
// "Address_id,Nickname,Firstname,Lastname,Title,Birthday,Comments,
......
......@@ -98,7 +98,7 @@ void CheckDuplicateEmailsJobTest::shouldReturnEmails_data()
void CheckDuplicateEmailsJobTest::shouldReturnEmails()
{
QFETCH(QStringList, emails);
typedef QMap<QString, int> mapEmails;
using mapEmails = QMap<QString, int>;
QFETCH(mapEmails, result);
CheckDuplicateEmailsJob job;
job.setEmails(emails);
......
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