Commit 517cf133 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

GIT_SILENT: coding style

parent d896d826
Pipeline #38222 passed with stage
in 28 minutes and 42 seconds
......@@ -366,7 +366,7 @@ private Q_SLOTS:
Akonadi::Item item;
item.setMimeType(QStringLiteral("application/octet-stream"));
item.setParentCollection(inboxSourceCol);
item.setPayload(QByteArray{"Hello world!"});
item.setPayload(QByteArray {"Hello world!"});
auto createItem = new Akonadi::ItemCreateJob(item, inboxSourceCol, this);
AKVERIFYEXEC(createItem);
item = createItem->item();
......@@ -426,7 +426,7 @@ private Q_SLOTS:
Akonadi::Item item;
item.setMimeType(QStringLiteral("application/octet-stream"));
item.setParentCollection(inboxSourceCol);
item.setPayload(QByteArray{"Hello world!"});
item.setPayload(QByteArray {"Hello world!"});
auto createItem = new Akonadi::ItemCreateJob(item, inboxSourceCol, this);
AKVERIFYEXEC(createItem);
item = createItem->item();
......@@ -500,7 +500,7 @@ private Q_SLOTS:
Akonadi::Item item;
item.setMimeType(QStringLiteral("application/octet-stream"));
item.setParentCollection(inboxSourceCol);
item.setPayload(QByteArray{"Hello world!"});
item.setPayload(QByteArray {"Hello world!"});
auto createItem = new Akonadi::ItemCreateJob(item, inboxSourceCol, this);
AKVERIFYEXEC(createItem);
item = createItem->item();
......
......@@ -21,7 +21,7 @@ void UnifiedMailbox::load(const KConfigGroup &group)
mId = group.name();
mName = group.readEntry("name");
mIcon = group.readEntry("icon", QStringLiteral("folder-mail"));
mSources = listToSet(group.readEntry("sources", QList<qint64>{}));
mSources = listToSet(group.readEntry("sources", QList<qint64> {}));
// This is not authoritative, we will do collection discovery anyway
mCollectionId = group.readEntry("collectionId", -1ll);
}
......@@ -86,7 +86,7 @@ void UnifiedMailbox::addSourceCollection(qint64 source)
{
mSources.insert(source);
if (mManager) {
mManager->mMonitor.setCollectionMonitored(Akonadi::Collection{source});
mManager->mMonitor.setCollectionMonitored(Akonadi::Collection {source});
mManager->mSourceToBoxMap.insert({ source, this });
}
}
......@@ -95,7 +95,7 @@ void UnifiedMailbox::removeSourceCollection(qint64 source)
{
mSources.remove(source);
if (mManager) {
mManager->mMonitor.setCollectionMonitored(Akonadi::Collection{source}, false);
mManager->mMonitor.setCollectionMonitored(Akonadi::Collection {source}, false);
mManager->mSourceToBoxMap.erase(source);
}
}
......@@ -121,12 +121,12 @@ void UnifiedMailbox::attachManager(UnifiedMailboxManager *manager)
if (manager) {
// Force that we start monitoring all the collections
for (const auto source : qAsConst(mSources)) {
manager->mMonitor.setCollectionMonitored(Akonadi::Collection{source});
manager->mMonitor.setCollectionMonitored(Akonadi::Collection {source});
manager->mSourceToBoxMap.insert({ source, this });
}
} else {
for (const auto &source : qAsConst(mSources)) {
mManager->mMonitor.setCollectionMonitored(Akonadi::Collection{source}, false);
mManager->mMonitor.setCollectionMonitored(Akonadi::Collection {source}, false);
mManager->mSourceToBoxMap.erase(source);
}
}
......
......@@ -87,7 +87,7 @@ UnifiedMailboxManager::UnifiedMailboxManager(const KSharedConfigPtr &config, QOb
return;
}
new Akonadi::LinkJob(Akonadi::Collection{box->collectionId()}, {item}, this);
new Akonadi::LinkJob(Akonadi::Collection {box->collectionId()}, {item}, this);
});
connect(&mMonitor, &Akonadi::Monitor::itemsRemoved,
this, [this](const Akonadi::Item::List &items) {
......@@ -110,7 +110,7 @@ UnifiedMailboxManager::UnifiedMailboxManager(const KSharedConfigPtr &config, QOb
return;
}
new Akonadi::UnlinkJob(Akonadi::Collection{box->collectionId()}, items, this);
new Akonadi::UnlinkJob(Akonadi::Collection {box->collectionId()}, items, this);
});
connect(&mMonitor, &Akonadi::Monitor::itemsMoved,
this, [this](const Akonadi::Item::List &items, const Akonadi::Collection &srcCollection,
......@@ -119,11 +119,11 @@ UnifiedMailboxManager::UnifiedMailboxManager(const KSharedConfigPtr &config, QOb
if (const auto srcBox = unifiedMailboxForSource(srcCollection.id())) {
// Move source collection was our source, unlink the Item from a box
new Akonadi::UnlinkJob(Akonadi::Collection{srcBox->collectionId()}, items, this);
new Akonadi::UnlinkJob(Akonadi::Collection {srcBox->collectionId()}, items, this);
}
if (const auto dstBox = unifiedMailboxForSource(dstCollection.id())) {
// Move destination collection is our source, link the Item into a box
new Akonadi::LinkJob(Akonadi::Collection{dstBox->collectionId()}, items, this);
new Akonadi::LinkJob(Akonadi::Collection {dstBox->collectionId()}, items, this);
}
});
......
......@@ -137,10 +137,10 @@ void RefreshSettingsCleanupPage::initCleanupDialogSettings(const QString &config
QStringLiteral("MailSourceWebEngineViewer"),
QStringLiteral("SelectAddressBookDialog"),
QStringLiteral("VCardViewer"),
QStringLiteral("MailSourceWebEngineViewer"),
QStringLiteral("ConfigurePluginsWidget"),
QStringLiteral("ConfigureAgentsWidget"),
QStringLiteral("AuditLogViewer")};
QStringLiteral("MailSourceWebEngineViewer"),
QStringLiteral("ConfigurePluginsWidget"),
QStringLiteral("ConfigureAgentsWidget"),
QStringLiteral("AuditLogViewer")};
for (const QString &str : dialogListName) {
KConfigGroup oldGroup = settingsrc->group(str);
cleanupFolderSettings(oldGroup);
......
......@@ -53,4 +53,3 @@ void CollectionTemplatesPage::save(Collection &col)
{
mCollectionTemplateWidget->save(col);
}
......@@ -107,7 +107,6 @@ void CollectionViewPage::slotChangeIcon(const QString &icon)
mUnreadIconButton->setIcon(icon);
}
void CollectionViewPage::load(const Akonadi::Collection &col)
{
init(col);
......
......@@ -74,7 +74,6 @@
#include <Libkdepim/ProgressStatusBarWidget>
#include <Libkdepim/StatusbarProgressWidget>
#include <KCursorSaver>
#include <Libkleo/KeySelectionDialog>
......@@ -120,7 +119,6 @@
#include <MessageComposer/PluginEditorConverterBeforeConvertingData>
#include <MessageComposer/FollowupReminder>
#include <Sonnet/DictionaryComboBox>
#include <MessageCore/AttachmentPart>
......
......@@ -71,7 +71,6 @@ void OpenComposerJob::start()
mMsg->inReplyTo()->fromUnicodeString(mOpenComposerSettings.mInReplyTo, "utf-8");
}
if (!mOpenComposerSettings.mMessageFile.isEmpty() && QFile::exists(mOpenComposerSettings.mMessageFile)) {
QFile f(mOpenComposerSettings.mMessageFile);
QByteArray str;
......
......@@ -1418,7 +1418,7 @@ KMCopyDecryptedCommand::KMCopyDecryptedCommand(const Akonadi::Collection &destFo
}
KMCopyDecryptedCommand::KMCopyDecryptedCommand(const Akonadi::Collection &destFolder, const Akonadi::Item &msg)
: KMCopyDecryptedCommand(destFolder, Akonadi::Item::List{ msg })
: KMCopyDecryptedCommand(destFolder, Akonadi::Item::List { msg })
{
}
......@@ -1604,7 +1604,7 @@ KMTrashMsgCommand::TrashOperation KMTrashMsgCommand::operation() const
}
KMTrashMsgCommand::KMTrashMsgCommand(const Akonadi::Collection &srcFolder, const Akonadi::Item &msg, MessageList::Core::MessageItemSetReference ref)
: KMTrashMsgCommand(srcFolder, Akonadi::Item::List{msg}, ref)
: KMTrashMsgCommand(srcFolder, Akonadi::Item::List {msg}, ref)
{
}
......
......@@ -1663,7 +1663,7 @@ void KMKernel::updatedTemplates()
void KMKernel::cleanupTemporaryFiles()
{
QDir dir(QDir::tempPath());
const QStringList lst = dir.entryList(QStringList{QStringLiteral("messageviewer_*")});
const QStringList lst = dir.entryList(QStringList {QStringLiteral("messageviewer_*")});
qCDebug(KMAIL_LOG) << " list file to delete " << lst;
for (const QString &file : lst) {
QFile tempFile(QDir::tempPath() + QLatin1Char('/') + file);
......@@ -1673,7 +1673,7 @@ void KMKernel::cleanupTemporaryFiles()
fprintf(stderr, "%s was removed .\n", qPrintable(tempFile.fileName()));
}
}
const QStringList lstRepo = dir.entryList(QStringList{QStringLiteral("messageviewer_*.index.*")});
const QStringList lstRepo = dir.entryList(QStringList {QStringLiteral("messageviewer_*.index.*")});
qCDebug(KMAIL_LOG) << " list repo to delete " << lstRepo;
for (const QString &file : lstRepo) {
QDir tempDir(QDir::tempPath() + QLatin1Char('/') + file);
......
......@@ -442,7 +442,6 @@ void KMReaderMainWin::initializeAkonadiStandardAction()
mAkonadiStandardActionManager->interceptAction(mailAction);
connect(act, &QAction::triggered, this, &KMReaderMainWin::slotMarkMailAs);
}
}
void KMReaderMainWin::slotMarkMailAs()
......@@ -450,7 +449,6 @@ void KMReaderMainWin::slotMarkMailAs()
const QAction *action = qobject_cast<QAction *>(sender());
Q_ASSERT(action);
const QByteArray typeStr = action->data().toByteArray();
mAkonadiStandardActionManager->markItemsAs(typeStr, {mMsgActions->currentItem()}, false);
......
......@@ -24,15 +24,15 @@ ManageShowCollectionProperties::ManageShowCollectionProperties(KMMainWidget *mai
: QObject(parent)
, mMainWidget(mainWidget)
, mPages({QStringLiteral("MailCommon::CollectionGeneralPage")
, QStringLiteral("KMail::CollectionViewPage")
, QStringLiteral("Akonadi::CachePolicyPage")
, QStringLiteral("KMail::CollectionTemplatesPage")
, QStringLiteral("MailCommon::CollectionExpiryPage")
, QStringLiteral("PimCommon::CollectionAclPage")
, QStringLiteral("KMail::CollectionMailingListPage")
, QStringLiteral("KMail::CollectionQuotaPage")
, QStringLiteral("KMail::CollectionShortcutPage")
, QStringLiteral("Akonadi::CollectionMaintenancePage")})
, QStringLiteral("KMail::CollectionViewPage")
, QStringLiteral("Akonadi::CachePolicyPage")
, QStringLiteral("KMail::CollectionTemplatesPage")
, QStringLiteral("MailCommon::CollectionExpiryPage")
, QStringLiteral("PimCommon::CollectionAclPage")
, QStringLiteral("KMail::CollectionMailingListPage")
, QStringLiteral("KMail::CollectionQuotaPage")
, QStringLiteral("KMail::CollectionShortcutPage")
, QStringLiteral("Akonadi::CollectionMaintenancePage")})
{
}
......
......@@ -101,7 +101,6 @@ MessageActions::MessageActions(KActionCollection *ac, QWidget *parent)
mStatusMenu = new KActionMenu(i18n("Mar&k Message"), this);
ac->addAction(QStringLiteral("set_status"), mStatusMenu);
mAnnotateAction = new QAction(QIcon::fromTheme(QStringLiteral("view-pim-notes")), i18n("Add Note..."), this);
ac->addAction(QStringLiteral("annotate"), mAnnotateAction);
connect(mAnnotateAction, &QAction::triggered, this, &MessageActions::annotateMessage);
......
......@@ -27,7 +27,6 @@ TagMonitorManager::TagMonitorManager(QObject *parent)
TagMonitorManager::~TagMonitorManager()
{
}
TagMonitorManager *TagMonitorManager::self()
......
......@@ -24,7 +24,6 @@ public:
static TagMonitorManager *self();
Q_REQUIRED_RESULT QVector<MailCommon::Tag::Ptr> tags() const;
Q_SIGNALS:
......
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