aboutsummaryrefslogtreecommitdiff
path: root/lib/settings
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2018-01-04 13:16:13 +0100
committerAqua-sama <aqua@iserlohn-fortress.net>2018-01-04 13:16:13 +0100
commitfad0abffec1ba784256daa68c7d52891c2d08825 (patch)
treed7d255805500e1f2598ef6aea7b21ca116a1b1df /lib/settings
parentFixed crash with Settings dialog (diff)
downloadsmolbote-fad0abffec1ba784256daa68c7d52891c2d08825.tar.xz
Various minor fixes
- typo fixes - bumped copyright year - removed a bunch of unused imports - fixed a couple of clazy warnings
Diffstat (limited to 'lib/settings')
-rw-r--r--lib/settings/settingsdialog.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/settings/settingsdialog.cpp b/lib/settings/settingsdialog.cpp
index 9a589d6..478e372 100644
--- a/lib/settings/settingsdialog.cpp
+++ b/lib/settings/settingsdialog.cpp
@@ -74,11 +74,11 @@ inline QHBoxLayout *createEntry(Configuration* config, const std::string &path,
QToolButton *resetButton = new QToolButton(widget);
resetButton->setIcon(widget->style()->standardIcon(QStyle::SP_DialogResetButton));
- QObject::connect(resetButton, &QToolButton::clicked, [config, path, lineEdit]() {
+ QObject::connect(resetButton, &QToolButton::clicked, widget, [config, path, lineEdit]() {
config->resetValue(path.c_str());
lineEdit->setText(QString::fromStdString(config->value<std::string>(path.c_str()).value()));
});
- QObject::connect(lineEdit, &QLineEdit::editingFinished, [config, path, lineEdit]() {
+ QObject::connect(lineEdit, &QLineEdit::editingFinished, widget, [config, path, lineEdit]() {
config->setValue<std::string>(path, lineEdit->text().toStdString());
});