Commit 4ebce93c authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Qt guys reverted api in qt5.15

parent 6a260ba6
......@@ -568,11 +568,7 @@ Kleo::CryptoConfigEntryDebugLevel::CryptoConfigEntryDebugLevel(CryptoConfigModul
label->setEnabled(false);
mComboBox->setEnabled(false);
} else {
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
connect(mComboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
#else
connect(mComboBox, QOverload<int, const QString &>::of(&QComboBox::currentIndexChanged),
#endif
this, &CryptoConfigEntryDebugLevel::slotChanged);
}
......
......@@ -376,11 +376,7 @@ KeySelectionCombo::KeySelectionCombo(bool secretOnly, QWidget* parent)
d->proxyModel->setSourceModel(d->sortFilterProxy);
setModel(d->proxyModel);
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
connect(this, static_cast<void(KeySelectionCombo::*)(int)>(&KeySelectionCombo::currentIndexChanged),
#else
connect(this, static_cast<void(KeySelectionCombo::*)(int, const QString &)>(&KeySelectionCombo::currentIndexChanged),
#endif
this, [this](int row) {
if (row >= 0 && row < d->proxyModel->rowCount()) {
if (d->proxyModel->isCustomItem(row)) {
......@@ -436,11 +432,7 @@ void KeySelectionCombo::init()
Q_EMIT keyListingFinished();
}
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
connect(this, QOverload<int>::of(&QComboBox::currentIndexChanged), this, [this] () {
#else
connect(this, QOverload<int, const QString &>::of(&QComboBox::currentIndexChanged), this, [this] () {
#endif
setToolTip(currentData(Qt::ToolTipRole).toString());
});
}
......
......@@ -490,11 +490,7 @@ public:
connect(combo, &KeySelectionCombo::currentKeyChanged, q, [this] () {
updateOkButton();
});
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
connect(combo, QOverload<int>::of(&QComboBox::currentIndexChanged), q, [this] () {
#else
connect(combo, QOverload<int, const QString &>::of(&QComboBox::currentIndexChanged), q, [this] () {
#endif
updateOkButton();
});
......@@ -575,11 +571,7 @@ public:
connect(combo, &KeySelectionCombo::currentKeyChanged, q, [this] () {
updateOkButton();
});
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
connect(combo, QOverload<int>::of(&QComboBox::currentIndexChanged), q, [this] () {
#else
connect(combo, QOverload<int, const QString &>::of(&QComboBox::currentIndexChanged), q, [this] () {
#endif
updateOkButton();
});
......
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