Merge pull request #9015 from thalieht/style

Fix coding style
This commit is contained in:
Vladimir Golovnev
2018-06-03 14:48:04 +03:00
committed by GitHub
28 changed files with 195 additions and 223 deletions

View File

@@ -38,7 +38,7 @@ namespace RSS
class Item;
}
class ArticleListWidget: public QListWidget
class ArticleListWidget : public QListWidget
{
Q_OBJECT

View File

@@ -50,8 +50,8 @@
#include "base/rss/rss_session.h"
#include "base/utils/fs.h"
#include "base/utils/string.h"
#include "guiiconprovider.h"
#include "autoexpandabledialog.h"
#include "guiiconprovider.h"
#include "ui_automatedrssdownloader.h"
#include "utils.h"
@@ -579,7 +579,7 @@ void AutomatedRssDownloader::updateMatchingArticles()
: RSS::AutoDownloader::instance()->ruleByName(ruleItem->text()));
foreach (const QString &feedURL, rule.feedURLs()) {
auto feed = RSS::Session::instance()->feedByURL(feedURL);
if (!feed) continue; // feed doesn't exists
if (!feed) continue; // feed doesn't exist
QStringList matchingArticles;
foreach (auto article, feed->articles())

View File

@@ -51,7 +51,7 @@ namespace RSS
class Feed;
}
class AutomatedRssDownloader: public QDialog
class AutomatedRssDownloader : public QDialog
{
Q_OBJECT

View File

@@ -41,7 +41,7 @@ namespace RSS
class Item;
}
class FeedListWidget: public QTreeWidget
class FeedListWidget : public QTreeWidget
{
Q_OBJECT

View File

@@ -308,7 +308,7 @@ void RSSWidget::loadFoldersOpenState()
const QStringList openedFolders = Preferences::instance()->getRssOpenFolders();
foreach (const QString &varPath, openedFolders) {
QTreeWidgetItem *parent = nullptr;
foreach (const QString &name, varPath.split("\\")) {
foreach (const QString &name, varPath.split('\\')) {
int nbChildren = (parent ? parent->childCount() : m_feedListWidget->topLevelItemCount());
for (int i = 0; i < nbChildren; ++i) {
QTreeWidgetItem *child = (parent ? parent->child(i) : m_feedListWidget->topLevelItem(i));
@@ -414,7 +414,7 @@ void RSSWidget::copySelectedFeedsURL()
if (auto feed = qobject_cast<RSS::Feed *>(m_feedListWidget->getRSSItem(item)))
URLs << feed->url();
}
qApp->clipboard()->setText(URLs.join("\n"));
qApp->clipboard()->setText(URLs.join('\n'));
}
void RSSWidget::handleCurrentFeedItemChanged(QTreeWidgetItem *currentItem)

View File

@@ -44,7 +44,7 @@ namespace Ui
class RSSWidget;
}
class RSSWidget: public QWidget
class RSSWidget : public QWidget
{
Q_OBJECT