[utilities/krusader] app: Dissolve no longer needed compat helper macro QCOMBOBOX_ACTIVATED

Toni Asensi Esteve <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 71a2cd41f4a658028e3df779f240e7018872eeac by Toni Asensi Esteve, on behalf of Friedrich W. H. Kossebau.
Committed on 19/07/2026 at 23:02.
Pushed by asensi into branch 'master'.

Dissolve no longer needed compat helper macro QCOMBOBOX_ACTIVATED

M  +1    -2    app/Dialogs/krmaskchoice.cpp
M  +2    -3    app/Dialogs/newftpgui.cpp
M  +1    -1    app/Dialogs/packguibase.cpp
M  +2    -3    app/Filter/generalfilter.cpp
M  +1    -2    app/Panel/panelfunc.cpp
M  +0    -14   app/compat.h

https://invent.kde.org/utilities/krusader/-/commit/71a2cd41f4a658028e3df779f240e7018872eeac

diff --git a/app/Dialogs/krmaskchoice.cpp b/app/Dialogs/krmaskchoice.cpp
index 73f79f037..600523ccc 100644
--- a/app/Dialogs/krmaskchoice.cpp
+++ b/app/Dialogs/krmaskchoice.cpp
@@ -23,7 +23,6 @@
 #include <KLocalizedString>
 
 #include "../GUI/krlistwidget.h"
-#include "../compat.h"
 
 /**
  * Constructs a KrMaskChoice which is a child of 'parent', with the
@@ -101,7 +100,7 @@ KrMaskChoice::KrMaskChoice(QWidget *parent)
     connect(PushButton7, &QPushButton::clicked, this, &KrMaskChoice::addSelection);
     connect(PushButton7_2, &QPushButton::clicked, this, &KrMaskChoice::deleteSelection);
     connect(PushButton7_3, &QPushButton::clicked, this, &KrMaskChoice::clearSelections);
-    connect(selection, QOverload<const QString &>::of(&KComboBox::QCOMBOBOX_ACTIVATED), selection, &KComboBox::setEditText);
+    connect(selection, &KComboBox::textActivated, selection, &KComboBox::setEditText);
     connect(selection->lineEdit(), &QLineEdit::returnPressed, this, &KrMaskChoice::accept);
     connect(preSelections, &KrListWidget::currentItemChanged, this, &KrMaskChoice::currentItemChanged);
     connect(preSelections, &KrListWidget::itemActivated, this, &KrMaskChoice::acceptFromList);
diff --git a/app/Dialogs/newftpgui.cpp b/app/Dialogs/newftpgui.cpp
index 7b8b4570a..69b3628fb 100644
--- a/app/Dialogs/newftpgui.cpp
+++ b/app/Dialogs/newftpgui.cpp
@@ -26,7 +26,6 @@
 #include <KProtocolInfo>
 #include <KSharedConfig>
 
-#include "../compat.h"
 #include "../icon.h"
 #include "../krglobal.h"
 
@@ -137,8 +136,8 @@ newFTPGUI::newFTPGUI(QWidget *parent)
     connect(buttonBox, &QDialogButtonBox::accepted, this, &newFTPGUI::accept);
     connect(buttonBox, &QDialogButtonBox::rejected, this, &newFTPGUI::reject);
 
-    connect(prefix, QOverload<const QString &>::of(&KComboBox::QCOMBOBOX_ACTIVATED), this, &newFTPGUI::slotTextChanged);
-    connect(url, QOverload<const QString &>::of(&KrHistoryComboBox::QCOMBOBOX_ACTIVATED), url, &KrHistoryComboBox::addToHistory);
+    connect(prefix, &KComboBox::textActivated, this, &newFTPGUI::slotTextChanged);
+    connect(url, &KrHistoryComboBox::textActivated, url, &KrHistoryComboBox::addToHistory);
 
     if (!lastUsedProtocol.isEmpty()) {
         // update the port field
diff --git a/app/Dialogs/packguibase.cpp b/app/Dialogs/packguibase.cpp
index d31d041d7..920653882 100644
--- a/app/Dialogs/packguibase.cpp
+++ b/app/Dialogs/packguibase.cpp
@@ -76,7 +76,7 @@ PackGUIBase::PackGUIBase(QWidget *parent)
 
     typeData = new QComboBox(this);
     typeData->setSizePolicy(QSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed));
-    connect(typeData, QOverload<const QString &>::of(&QComboBox::QCOMBOBOX_ACTIVATED), this, &PackGUIBase::checkConsistency);
+    connect(typeData, &QComboBox::textActivated, this, &PackGUIBase::checkConsistency);
     connect(typeData, QOverload<const QString &>::of(&QComboBox::QCOMBOBOX_HIGHLIGHTED), this, &PackGUIBase::checkConsistency);
     hbox->addWidget(typeData);
 
diff --git a/app/Filter/generalfilter.cpp b/app/Filter/generalfilter.cpp
index e27f9dc20..1b5902df5 100644
--- a/app/Filter/generalfilter.cpp
+++ b/app/Filter/generalfilter.cpp
@@ -9,7 +9,6 @@
 
 #include "generalfilter.h"
 #include "../FileSystem/filesystem.h"
-#include "../compat.h"
 #include "../krglobal.h"
 #include "../krservices.h"
 #include "filtertabs.h"
@@ -384,8 +383,8 @@ GeneralFilter::GeneralFilter(FilterTabs *tabs, int properties, QWidget *parent,
         connect(profileManager, &ProfileManager::saveToProfile, fltTabs, &FilterTabs::saveToProfile);
     }
 
-    connect(searchFor, QOverload<const QString &>::of(&KrHistoryComboBox::QCOMBOBOX_ACTIVATED), searchFor, &KrHistoryComboBox::addToHistory);
-    connect(containsText, QOverload<const QString &>::of(&KrHistoryComboBox::QCOMBOBOX_ACTIVATED), containsText, &KrHistoryComboBox::addToHistory);
+    connect(searchFor, &KrHistoryComboBox::textActivated, searchFor, &KrHistoryComboBox::addToHistory);
+    connect(containsText, &KrHistoryComboBox::textActivated, containsText, &KrHistoryComboBox::addToHistory);
 
     // load the completion and history lists
     // ==> search for
diff --git a/app/Panel/panelfunc.cpp b/app/Panel/panelfunc.cpp
index 5549aa0d7..abb02e39e 100644
--- a/app/Panel/panelfunc.cpp
+++ b/app/Panel/panelfunc.cpp
@@ -63,7 +63,6 @@
 #include "../KrViewer/krviewer.h"
 #include "../MountMan/kmountman.h"
 #include "../abstractpanelmanager.h"
-#include "../compat.h"
 #include "../defaults.h"
 #include "../kractions.h"
 #include "../krglobal.h"
@@ -712,7 +711,7 @@ void ListPanelFunc::mkdir()
     connect(&buttonBox, &QDialogButtonBox::accepted, &dialog, &QDialog::accept);
     connect(&buttonBox, &QDialogButtonBox::rejected, &dialog, &QDialog::reject);
 
-    connect(&comboBox, QOverload<const QString &>::of(&KrHistoryComboBox::QCOMBOBOX_ACTIVATED), &comboBox, &KrHistoryComboBox::addToHistory);
+    connect(&comboBox, &KrHistoryComboBox::textActivated, &comboBox, &KrHistoryComboBox::addToHistory);
 
     // ------------------------------------------------------------------------
     // load the history and completion list after creating the KrHistoryComboBox
diff --git a/app/compat.h b/app/compat.h
index 5d3d3c7bf..fdeb23b31 100644
--- a/app/compat.h
+++ b/app/compat.h
@@ -7,20 +7,6 @@
 #ifndef _COMPAT_H_
 #define _COMPAT_H_
 
-/**
- * QComboBox::activated(const QString &text) was made obsoleted in QT 5.15 in
- * favor of QComboBox::textActivated(const QString &text)
- *
- * https://doc.qt.io/qt-5.15/qcombobox-obsolete.html#activated-1
- *
- * This can be removed when the qt minimum version required will be >= 5.15
- */
-#if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
-#define QCOMBOBOX_ACTIVATED textActivated
-#else
-#define QCOMBOBOX_ACTIVATED activated
-#endif
-
 /**
  * QComboBox::highlighted(const QString &text) was made obsoleted in QT 5.15 in
  * favor of QComboBox::textHighlighted(const QString &text)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.