aboutsummaryrefslogtreecommitdiff
path: root/lib/settings/settingsdialog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/settings/settingsdialog.cpp')
-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());
});