Commit 8390b4eb authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Fix enable/disable ok button

parent b8906845
......@@ -27,7 +27,8 @@ FilterNameWidget::FilterNameWidget(QWidget *parent)
mainLayout->addWidget(label);
mainLayout->addWidget(mName);
connect(mName, &QLineEdit::textChanged, this, [this](const QString &str) {
Q_EMIT updateOkButton(!str.trimmed().isEmpty());
const QString trimmedStr = str.trimmed();
Q_EMIT updateOkButton(!trimmedStr.isEmpty() && !mFilterListNames.contains(trimmedStr));
});
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment