aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/about/aboutdialog.cpp14
-rw-r--r--lib/bookmarks/bookmarksview.h1
-rw-r--r--lib/bookmarks/bookmarkswidget.cpp2
-rw-r--r--lib/bookmarks/bookmarkswidget.h4
-rw-r--r--lib/bookmarks/xbel.h2
-rw-r--r--lib/configuration/configuration.h16
-rw-r--r--lib/downloads/widgets/downloaditemwidget.cpp2
7 files changed, 20 insertions, 21 deletions
diff --git a/lib/about/aboutdialog.cpp b/lib/about/aboutdialog.cpp
index ff4200f..1d60eb4 100644
--- a/lib/about/aboutdialog.cpp
+++ b/lib/about/aboutdialog.cpp
@@ -33,7 +33,8 @@ AboutDialog::AboutDialog(QWidget *parent)
auto *aboutLabel = new QLabel(this);
aboutLabel->setWordWrap(true);
aboutLabel->setText(tr("<h2>smolbote %1</h2>"
- "<p><i>yet another no-frills browser</i></p>").arg(qApp->applicationVersion()));
+ "<p><i>yet another no-frills browser</i></p>")
+ .arg(qApp->applicationVersion()));
ui->toolBox->addItem(aboutLabel, tr("About"));
auto *licenseLabel = new QLabel(this);
@@ -53,13 +54,12 @@ AboutDialog::AboutDialog(QWidget *parent)
auto *detailsLabel = new QLabel(this);
detailsLabel->setWordWrap(true);
detailsLabel->setText(tr("<p>Compiled with " compiler "</p>"
- "<p><ul>"
- "<li>Qt " QT_VERSION_STR "</li>"
- "<li>QtWebEngine " QTWEBENGINE_VERSION_STR "</li>"
- "<li>Boost " BOOST_LIB_VERSION " </li>"
- "</ul></p>"));
+ "<p><ul>"
+ "<li>Qt " QT_VERSION_STR "</li>"
+ "<li>QtWebEngine " QTWEBENGINE_VERSION_STR "</li>"
+ "<li>Boost " BOOST_LIB_VERSION " </li>"
+ "</ul></p>"));
ui->toolBox->addItem(detailsLabel, tr("Details"));
-
}
AboutDialog::~AboutDialog()
diff --git a/lib/bookmarks/bookmarksview.h b/lib/bookmarks/bookmarksview.h
index 5b408e0..47b3f9c 100644
--- a/lib/bookmarks/bookmarksview.h
+++ b/lib/bookmarks/bookmarksview.h
@@ -34,5 +34,4 @@ private:
QIcon bookmarkIcon;
};
-
#endif // SMOLBOTE_BOOKMARKSVIEW_H
diff --git a/lib/bookmarks/bookmarkswidget.cpp b/lib/bookmarks/bookmarkswidget.cpp
index 339e913..cae1eb3 100644
--- a/lib/bookmarks/bookmarkswidget.cpp
+++ b/lib/bookmarks/bookmarkswidget.cpp
@@ -129,7 +129,7 @@ void BookmarksWidget::save()
}
}
-void BookmarksWidget::search(const QString& term, std::function<void(QStringList&)> callback) const
+void BookmarksWidget::search(const QString &term, std::function<void(QStringList &)> callback) const
{
QStringList ret;
const QList<QTreeWidgetItem *> res = ui->treeWidget->findItems(term, Qt::MatchContains | Qt::MatchRecursive, 1);
diff --git a/lib/bookmarks/bookmarkswidget.h b/lib/bookmarks/bookmarkswidget.h
index 6322918..40f5c04 100644
--- a/lib/bookmarks/bookmarkswidget.h
+++ b/lib/bookmarks/bookmarkswidget.h
@@ -9,9 +9,9 @@
#ifndef BOOKMARKSDIALOG_H
#define BOOKMARKSDIALOG_H
+#include <QFile>
#include <QShortcut>
#include <QWidget>
-#include <QFile>
#include <functional>
namespace Ui
@@ -35,7 +35,7 @@ signals:
void openUrl(const QUrl &url);
public slots:
- void search(const QString &term, std::function<void(QStringList&)> callback) const;
+ void search(const QString &term, std::function<void(QStringList &)> callback) const;
private:
Ui::BookmarksDialog *ui;
diff --git a/lib/bookmarks/xbel.h b/lib/bookmarks/xbel.h
index 6981627..ecc185a 100644
--- a/lib/bookmarks/xbel.h
+++ b/lib/bookmarks/xbel.h
@@ -9,9 +9,9 @@
#ifndef XBELREADER_H
#define XBELREADER_H
+#include "bookmarksview.h"
#include <QString>
#include <QXmlStreamReader>
-#include "bookmarksview.h"
class XbelReader
{
diff --git a/lib/configuration/configuration.h b/lib/configuration/configuration.h
index 1c919b0..c5e044f 100644
--- a/lib/configuration/configuration.h
+++ b/lib/configuration/configuration.h
@@ -9,13 +9,13 @@
#ifndef SMOLBOTE_CONFIGURATION_H
#define SMOLBOTE_CONFIGURATION_H
-#include <optional>
-#include <string>
-#include <vector>
#include <QString>
-#include <boost/program_options.hpp>
#include <QStringList>
#include <QVariant>
+#include <boost/program_options.hpp>
+#include <optional>
+#include <string>
+#include <vector>
class Configuration
{
@@ -43,16 +43,15 @@ public:
std::string r;
try {
r = vm[path].as<std::string>();
- } catch (boost::bad_any_cast &) {
+ } catch(boost::bad_any_cast &) {
// try int
try {
r = std::to_string(vm[path].as<int>());
- } catch (boost::bad_any_cast &) {
+ } catch(boost::bad_any_cast &) {
// try bool, and crash if not that either
r = vm[path].as<bool>() ? "true" : "false";
}
-
}
// check if it's a path
@@ -65,7 +64,8 @@ public:
return std::optional<T>(vm[path].as<T>());
}
- const std::vector<boost::shared_ptr<boost::program_options::option_description>> & options() {
+ const std::vector<boost::shared_ptr<boost::program_options::option_description>> &options()
+ {
return desc.options();
}
diff --git a/lib/downloads/widgets/downloaditemwidget.cpp b/lib/downloads/widgets/downloaditemwidget.cpp
index 576ae0c..2790c5c 100644
--- a/lib/downloads/widgets/downloaditemwidget.cpp
+++ b/lib/downloads/widgets/downloaditemwidget.cpp
@@ -8,8 +8,8 @@
#include "downloaditemwidget.h"
#include "ui_downloaditemform.h"
-#include <QUrl>
#include <QStyle>
+#include <QUrl>
DownloadItemWidget::DownloadItemWidget(QWebEngineDownloadItem *item, QWidget *parent)
: QWidget(parent)