Git commit a69df1246048ce90ede89a1332eb3fc9f7e58504 by Montel Laurent. Committed on 31/10/2017 at 21:32. Pushed by mlaurent into branch 'master'. GIT_SILENT: coding style M +1 -1 plugins/mk4storage/feedstoragemk4impl.cpp M +2 -2 src/akregator_part.cpp M +3 -1 src/command/createfeedcommand.cpp M +3 -1 src/command/createfoldercommand.cpp M +6 -2 src/command/deletesubscriptioncommand.cpp M +3 -1 src/command/editsubscriptioncommand.cpp M +6 -2 src/command/expireitemscommand.cpp M +3 -1 src/command/importfeedlistcommand.cpp M +3 -1 src/command/loadfeedlistcommand.cpp M +2 -2 src/selectioncontroller.cpp M +6 -3 src/subscription/subscriptionlistmodel.cpp M +1 -1 src/subscription/subscriptionlistmodel.h M +1 -1 src/subscription/subscriptionlistview.cpp https://commits.kde.org/akregator/a69df1246048ce90ede89a1332eb3fc9f7e58504 diff --git a/plugins/mk4storage/feedstoragemk4impl.cpp b/plugins/mk4storage= /feedstoragemk4impl.cpp index 39ecf57d..82127ede 100644 --- a/plugins/mk4storage/feedstoragemk4impl.cpp +++ b/plugins/mk4storage/feedstoragemk4impl.cpp @@ -151,7 +151,7 @@ FeedStorageMK4Impl::FeedStorageMK4Impl(const QString &u= rl, StorageMK4Impl *main) = = ':'), = = QLatin1Char( = = '_')) - + QLatin1String(".xml"); + + QLatin1String(".xml"); d->convert =3D !QFile::exists(filePath + QLatin1String(".mk4")) && QFi= le::exists(d->oldArchivePath); d->storage =3D new c4_Storage(QString(filePath + QLatin1String(".mk4")= ).toLocal8Bit(), true); = diff --git a/src/akregator_part.cpp b/src/akregator_part.cpp index 4d5f8be3..94a4e00b 100644 --- a/src/akregator_part.cpp +++ b/src/akregator_part.cpp @@ -155,8 +155,8 @@ static QDomDocument createDefaultFeedList() } = namespace Akregator { - -K_PLUGIN_FACTORY(AkregatorFactory, registerPlugin();) +K_PLUGIN_FACTORY(AkregatorFactory, registerPlugin(); + ) = static Part *mySelf =3D nullptr; BrowserExtension::BrowserExtension(Part *p, const char *name) diff --git a/src/command/createfeedcommand.cpp b/src/command/createfeedcomm= and.cpp index 9c0c20b4..b10969cd 100644 --- a/src/command/createfeedcommand.cpp +++ b/src/command/createfeedcommand.cpp @@ -176,7 +176,9 @@ void CreateFeedCommand::setAutoExecute(bool autoexec) = void CreateFeedCommand::doStart() { - QTimer::singleShot(0, this, [this]() { d->doCreate(); }); + QTimer::singleShot(0, this, [this]() { + d->doCreate(); + }); } = void CreateFeedCommand::doAbort() diff --git a/src/command/createfoldercommand.cpp b/src/command/createfolder= command.cpp index a8e28b3e..ef388b53 100644 --- a/src/command/createfoldercommand.cpp +++ b/src/command/createfoldercommand.cpp @@ -114,7 +114,9 @@ void CreateFolderCommand::setRootFolder(Folder *rootFol= der) = void CreateFolderCommand::doStart() { - QTimer::singleShot(0, this, [this]() { d->doCreate(); }); + QTimer::singleShot(0, this, [this]() { + d->doCreate(); + }); } = void CreateFolderCommand::doAbort() diff --git a/src/command/deletesubscriptioncommand.cpp b/src/command/delete= subscriptioncommand.cpp index 1970021e..1545f74a 100644 --- a/src/command/deletesubscriptioncommand.cpp +++ b/src/command/deletesubscriptioncommand.cpp @@ -165,7 +165,9 @@ QWeakPointer DeleteSubscriptionCommand::feedL= ist() const = void DeleteSubscriptionCommand::doStart() { - QTimer::singleShot(0, this, [this]() { d->startDelete(); }); + QTimer::singleShot(0, this, [this]() { + d->startDelete(); + }); } = void DeleteSubscriptionCommand::Private::jobFinished() @@ -188,7 +190,9 @@ void DeleteSubscriptionCommand::Private::startDelete() return; } = - QObject::connect(job, &DeleteSubscriptionJob::finished, q, [this]() { = jobFinished(); }); + QObject::connect(job, &DeleteSubscriptionJob::finished, q, [this]() { + jobFinished(); + }); job->start(); } = diff --git a/src/command/editsubscriptioncommand.cpp b/src/command/editsubs= criptioncommand.cpp index de009e56..64944a82 100644 --- a/src/command/editsubscriptioncommand.cpp +++ b/src/command/editsubscriptioncommand.cpp @@ -137,7 +137,9 @@ void EditSubscriptionCommand::setSubscriptionListView(S= ubscriptionListView *view = void EditSubscriptionCommand::doStart() { - QTimer::singleShot(0, this, [this]() { d->startEdit(); }); + QTimer::singleShot(0, this, [this]() { + d->startEdit(); + }); } = void EditSubscriptionCommand::Private::startEdit() diff --git a/src/command/expireitemscommand.cpp b/src/command/expireitemsco= mmand.cpp index 845d1f9b..4560953e 100644 --- a/src/command/expireitemscommand.cpp +++ b/src/command/expireitemscommand.cpp @@ -63,7 +63,9 @@ void ExpireItemsCommand::Private::addDeleteJobForFeed(Fee= d *feed) { Q_ASSERT(feed); ArticleDeleteJob *job =3D new ArticleDeleteJob(q); - connect(job, &ArticleDeleteJob::finished, q, [this](KJob *job) { jobFi= nished(job); }); + connect(job, &ArticleDeleteJob::finished, q, [this](KJob *job) { + jobFinished(job); + }); m_jobs.insert(job); feed->deleteExpiredArticles(job); job->start(); @@ -139,7 +141,9 @@ void ExpireItemsCommand::doAbort() = void ExpireItemsCommand::doStart() { - QTimer::singleShot(0, this, [this]() { d->createDeleteJobs(); }); + QTimer::singleShot(0, this, [this]() { + d->createDeleteJobs(); + }); } = #include "moc_expireitemscommand.cpp" diff --git a/src/command/importfeedlistcommand.cpp b/src/command/importfeed= listcommand.cpp index 986fae3e..9d283ce8 100644 --- a/src/command/importfeedlistcommand.cpp +++ b/src/command/importfeedlistcommand.cpp @@ -152,7 +152,9 @@ void ImportFeedListCommand::doAbort() = void ImportFeedListCommand::doStart() { - QTimer::singleShot(0, this, [this]() { d->doImport(); }); + QTimer::singleShot(0, this, [this]() { + d->doImport(); + }); } = #include "moc_importfeedlistcommand.cpp" diff --git a/src/command/loadfeedlistcommand.cpp b/src/command/loadfeedlist= command.cpp index cdf90b76..004c9b96 100644 --- a/src/command/loadfeedlistcommand.cpp +++ b/src/command/loadfeedlistcommand.cpp @@ -132,7 +132,9 @@ void LoadFeedListCommand::setStorage(Backend::Storage *= s) = void LoadFeedListCommand::doStart() { - QTimer::singleShot(KRandom::random() % 400, this, [this]() { d->doLoad= (); }); + QTimer::singleShot(KRandom::random() % 400, this, [this]() { + d->doLoad(); + }); } = void LoadFeedListCommand::doAbort() diff --git a/src/selectioncontroller.cpp b/src/selectioncontroller.cpp index 5090d74f..d9df9f77 100644 --- a/src/selectioncontroller.cpp +++ b/src/selectioncontroller.cpp @@ -185,7 +185,7 @@ void Akregator::SelectionController::setFeedList(const = QSharedPointer } = m_feedList =3D list; - SubscriptionListModel *m =3D qobject_cast(m_su= bscriptionModel->sourceModel()); + SubscriptionListModel *m =3D qobject_cast(m_s= ubscriptionModel->sourceModel()); std::unique_ptr oldModel(m); m_subscriptionModel->setSourceModel(new SubscriptionListModel(m_feedLi= st, this)); = @@ -264,7 +264,7 @@ void Akregator::SelectionController::subscriptionDataCh= anged(const QModelIndex & } = //need access to setExpanded - QTreeView *tv =3D qobject_cast(m_feedSelector); + QTreeView *tv =3D qobject_cast(m_feedSelector); if (!tv) { qCCritical(AKREGATOR_LOG) << "Unable to cast m_feedSelector to QTr= eeView"; return; diff --git a/src/subscription/subscriptionlistmodel.cpp b/src/subscription/= subscriptionlistmodel.cpp index f433c9d3..d0ee9009 100644 --- a/src/subscription/subscriptionlistmodel.cpp +++ b/src/subscription/subscriptionlistmodel.cpp @@ -116,12 +116,14 @@ bool Akregator::FilterUnreadProxyModel::filterAccepts= Row(int source_row, const Q = QModelIndex idx =3D sourceModel()->index(source_row, 0, source_parent); = - if (m_selectedHierarchy.contains(idx)) + if (m_selectedHierarchy.contains(idx)) { return true; + } = QVariant v =3D idx.data(SubscriptionListModel::HasUnreadRole); - if (v.isNull()) + if (v.isNull()) { return true; + } = return v.toBool(); } @@ -158,8 +160,9 @@ void Akregator::FilterUnreadProxyModel::selectionChange= d(const QItemSelection &s } } = - if (doInvalidate && doFilter()) + if (doInvalidate && doFilter()) { invalidateFilter(); + } } = void Akregator::FilterUnreadProxyModel::clearCache() diff --git a/src/subscription/subscriptionlistmodel.h b/src/subscription/su= bscriptionlistmodel.h index 3dbb557b..2a02a488 100644 --- a/src/subscription/subscriptionlistmodel.h +++ b/src/subscription/subscriptionlistmodel.h @@ -45,7 +45,7 @@ class FilterUnreadProxyModel : public QSortFilterProxyMod= el { Q_OBJECT public: - explicit FilterUnreadProxyModel(QObject* parent =3D nullptr); + explicit FilterUnreadProxyModel(QObject *parent =3D nullptr); = bool doFilter() const; = diff --git a/src/subscription/subscriptionlistview.cpp b/src/subscription/s= ubscriptionlistview.cpp index 312aecc7..e91bbcbb 100644 --- a/src/subscription/subscriptionlistview.cpp +++ b/src/subscription/subscriptionlistview.cpp @@ -396,7 +396,7 @@ void SubscriptionListView::slotSetHideReadFeeds(bool se= tting) return; } = - FilterUnreadProxyModel *filter =3D qobject_cast(m); + FilterUnreadProxyModel *filter =3D qobject_cast(m); if (!filter) { qCCritical(AKREGATOR_LOG) << "Unable to cast model to FilterUnread= ProxyModel*"; return;