Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package kcompletion for openSUSE:Factory checked in at 2022-01-11 21:16:03 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/kcompletion (Old) and /work/SRC/openSUSE:Factory/.kcompletion.new.1892 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "kcompletion" Tue Jan 11 21:16:03 2022 rev:101 rq:945038 version:5.90.0 Changes: -------- --- /work/SRC/openSUSE:Factory/kcompletion/kcompletion.changes 2021-12-13 20:43:45.764480421 +0100 +++ /work/SRC/openSUSE:Factory/.kcompletion.new.1892/kcompletion.changes 2022-01-11 21:18:26.072923586 +0100 @@ -1,0 +2,10 @@ +Mon Jan 3 12:47:19 UTC 2022 - Christophe Giboudeaux <[email protected]> + +- Update to 5.90.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/5/5.90.0 +- Changes since 5.89.0: + * Change the build system to enable building with Qt 6 + +------------------------------------------------------------------- Old: ---- kcompletion-5.89.0.tar.xz kcompletion-5.89.0.tar.xz.sig New: ---- kcompletion-5.90.0.tar.xz kcompletion-5.90.0.tar.xz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ kcompletion.spec ++++++ --- /var/tmp/diff_new_pack.EoVtau/_old 2022-01-11 21:18:26.596923954 +0100 +++ /var/tmp/diff_new_pack.EoVtau/_new 2022-01-11 21:18:26.604923960 +0100 @@ -17,21 +17,21 @@ %define lname libKF5Completion5 -%define _tar_path 5.89 +%define _tar_path 5.90 # Full KF5 version (e.g. 5.33.0) %{!?_kf5_version: %global _kf5_version %{version}} # Last major and minor KF5 version (e.g. 5.33) %{!?_kf5_bugfix_version: %define _kf5_bugfix_version %(echo %{_kf5_version} | awk -F. '{print $1"."$2}')} -%bcond_without lang +%bcond_without released Name: kcompletion -Version: 5.89.0 +Version: 5.90.0 Release: 0 Summary: Widgets with advanced completion support License: LGPL-2.1-or-later Group: System/GUI/KDE URL: https://www.kde.org Source: %{name}-%{version}.tar.xz -%if %{with lang} +%if %{with released} Source1: %{name}-%{version}.tar.xz.sig Source2: frameworks.keyring %endif @@ -42,7 +42,7 @@ BuildRequires: cmake(KF5WidgetsAddons) >= %{_kf5_bugfix_version} BuildRequires: cmake(Qt5UiPlugin) >= 5.15.0 BuildRequires: cmake(Qt5Widgets) >= 5.15.0 -%if %{with lang} +%if %{with released} BuildRequires: cmake(Qt5LinguistTools) >= 5.15.0 %endif @@ -53,9 +53,6 @@ %package -n %{lname} Summary: Widgets with advanced completion support Group: System/GUI/KDE -%if %{with lang} -Recommends: %{lname}-lang = %{version} -%endif %description -n %{lname} KCompletion provides widgets with advanced completion support as well as a @@ -86,14 +83,14 @@ %kf5_makeinstall -C build %fdupes %{buildroot} -%if %{with lang} +%if %{with released} %find_lang %{name}5 --with-qt --without-mo %endif %post -n %{lname} -p /sbin/ldconfig %postun -n %{lname} -p /sbin/ldconfig -%if %{with lang} +%if %{with released} %files -n %{lname}-lang -f %{name}5.lang %endif ++++++ kcompletion-5.89.0.tar.xz -> kcompletion-5.90.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/CMakeLists.txt new/kcompletion-5.90.0/CMakeLists.txt --- old/kcompletion-5.89.0/CMakeLists.txt 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/CMakeLists.txt 2022-01-01 13:26:48.000000000 +0100 @@ -1,12 +1,12 @@ cmake_minimum_required(VERSION 3.16) -set(KF_VERSION "5.89.0") # handled by release scripts -set(KF_DEP_VERSION "5.89.0") # handled by release scripts +set(KF_VERSION "5.90.0") # handled by release scripts +set(KF_DEP_VERSION "5.90.0") # handled by release scripts project(KCompletion VERSION ${KF_VERSION}) # ECM setup include(FeatureSummary) -find_package(ECM 5.89.0 NO_MODULE) +find_package(ECM 5.90.0 NO_MODULE) set_package_properties(ECM PROPERTIES TYPE REQUIRED DESCRIPTION "Extra CMake Modules." URL "https://commits.kde.org/extra-cmake-modules") feature_summary(WHAT REQUIRED_PACKAGES_NOT_FOUND FATAL_ON_MISSING_REQUIRED_PACKAGES) @@ -34,7 +34,7 @@ # Dependencies set(REQUIRED_QT_VERSION 5.15.2) -find_package(Qt5 ${REQUIRED_QT_VERSION} NO_MODULE REQUIRED Widgets) +find_package(Qt${QT_MAJOR_VERSION} ${REQUIRED_QT_VERSION} NO_MODULE REQUIRED Widgets) find_package(KF5Config ${KF_DEP_VERSION} REQUIRED) find_package(KF5WidgetsAddons ${KF_DEP_VERSION} REQUIRED) @@ -48,7 +48,7 @@ add_feature_info(DESIGNERPLUGIN ${BUILD_DESIGNERPLUGIN} "Build plugin for Qt Designer") add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0x050f02) -add_definitions(-DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x055100) +add_definitions(-DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x055900) ecm_install_po_files_as_qm(po) add_subdirectory(src) @@ -89,7 +89,7 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/kcompletion_version.h - DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5} COMPONENT Devel + DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF} COMPONENT Devel ) feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/KF5CompletionConfig.cmake.in new/kcompletion-5.90.0/KF5CompletionConfig.cmake.in --- old/kcompletion-5.89.0/KF5CompletionConfig.cmake.in 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/KF5CompletionConfig.cmake.in 2022-01-01 13:26:48.000000000 +0100 @@ -1,7 +1,7 @@ @PACKAGE_INIT@ include(CMakeFindDependencyMacro) -find_dependency(Qt5Widgets @REQUIRED_QT_VERSION@) +find_dependency(Qt@QT_MAJOR_VERSION@Widgets @REQUIRED_QT_VERSION@) include("${CMAKE_CURRENT_LIST_DIR}/KF5CompletionTargets.cmake") @PACKAGE_INCLUDE_QCHTARGETS@ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/autotests/CMakeLists.txt new/kcompletion-5.90.0/autotests/CMakeLists.txt --- old/kcompletion-5.89.0/autotests/CMakeLists.txt 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/autotests/CMakeLists.txt 2022-01-01 13:26:48.000000000 +0100 @@ -1,10 +1,10 @@ remove_definitions(-DQT_NO_CAST_FROM_ASCII) remove_definitions(-DQT_NO_CAST_TO_ASCII) -find_package(Qt5Test ${REQUIRED_QT_VERSION} CONFIG QUIET) +find_package(Qt${QT_MAJOR_VERSION}Test ${REQUIRED_QT_VERSION} CONFIG QUIET) -if(NOT Qt5Test_FOUND) - message(STATUS "Qt5Test not found, autotests will not be built.") +if(NOT Qt${QT_MAJOR_VERSION}Test_FOUND) + message(STATUS "Qt${QT_MAJOR_VERSION}Test not found, autotests will not be built.") return() endif() @@ -15,5 +15,5 @@ klineedit_unittest.cpp kcombobox_unittest.cpp ksortablelisttest.cpp - LINK_LIBRARIES Qt5::Test KF5::Completion + LINK_LIBRARIES Qt${QT_MAJOR_VERSION}::Test KF5::Completion ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/po/ar/kcompletion5_qt.po new/kcompletion-5.90.0/po/ar/kcompletion5_qt.po --- old/kcompletion-5.89.0/po/ar/kcompletion5_qt.po 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/po/ar/kcompletion5_qt.po 2022-01-01 13:26:48.000000000 +0100 @@ -5,7 +5,7 @@ "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2014-06-28 15:38+0300\n" -"PO-Revision-Date: 2021-07-26 23:23+0400\n" +"PO-Revision-Date: 2021-12-21 17:27+0400\n" "Last-Translator: Zayed Al-Saidi <[email protected]>\n" "Language-Team: ar\n" "Language: ar\n" @@ -25,7 +25,7 @@ #: klineedit.cpp:98 msgctxt "KLineEdit|Italic placeholder text in line edits: 0 no, 1 yes" msgid "1" -msgstr "??" +msgstr "0" #: klineedit.cpp:939 msgctxt "KLineEdit|@action:inmenu" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/po/ca@valencia/kcompletion5_qt.po new/kcompletion-5.90.0/po/ca@valencia/kcompletion5_qt.po --- old/kcompletion-5.89.0/po/ca@valencia/kcompletion5_qt.po 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/po/ca@valencia/kcompletion5_qt.po 2022-01-01 13:26:48.000000000 +0100 @@ -6,17 +6,17 @@ # Sebasti?? Pla i Sanz <[email protected]>, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007. # Antoni Bella P??rez <[email protected]>, 2003, 2006, 2011, 2012, 2013, 2014. # Albert Astals Cid <[email protected]>, 2004, 2005, 2007. -# Josep Ma. Ferrer <[email protected]>, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014. +# Josep M. Ferrer <[email protected]>, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014. # Robert Millan <[email protected]>, 2009. # Orestes Mas <[email protected]>, 2010. -# Empar <[email protected]>, 2019. +# Empar Montoro Mart??n <[email protected]>, 2019. msgid "" msgstr "" "Project-Id-Version: kcompletion\n" "Report-Msgid-Bugs-To: https://bugs.kde.org\n" "POT-Creation-Date: 2014-03-23 01:50+0000\n" "PO-Revision-Date: 2019-06-17 12:33+0200\n" -"Last-Translator: Empar <[email protected]>\n" +"Last-Translator: Empar Montoro Mart??n <[email protected]>\n" "Language-Team: Catalan <[email protected]>\n" "Language: ca@valencia\n" "MIME-Version: 1.0\n" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/po/zh_CN/kcompletion5_qt.po new/kcompletion-5.90.0/po/zh_CN/kcompletion5_qt.po --- old/kcompletion-5.89.0/po/zh_CN/kcompletion5_qt.po 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/po/zh_CN/kcompletion5_qt.po 2022-01-01 13:26:48.000000000 +0100 @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: kdeorg\n" -"PO-Revision-Date: 2021-11-30 15:20\n" +"PO-Revision-Date: 2021-12-22 14:05\n" "Language-Team: Chinese Simplified\n" "Language: zh_CN\n" "MIME-Version: 1.0\n" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/src/CMakeLists.txt new/kcompletion-5.90.0/src/CMakeLists.txt --- old/kcompletion-5.89.0/src/CMakeLists.txt 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/src/CMakeLists.txt 2022-01-01 13:26:48.000000000 +0100 @@ -45,9 +45,9 @@ EXCLUDE_DEPRECATED_BEFORE_AND_AT ${EXCLUDE_DEPRECATED_BEFORE_AND_AT} ) -target_include_directories(KF5Completion INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF5}/KCompletion>") +target_include_directories(KF5Completion INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF}/KCompletion>") -target_link_libraries(KF5Completion PUBLIC Qt5::Widgets +target_link_libraries(KF5Completion PUBLIC Qt${QT_MAJOR_VERSION}::Widgets PRIVATE KF5::ConfigCore # KConfigGroup, used in many places KF5::ConfigGui # KStandardShortcut KF5::WidgetsAddons # KCursor @@ -101,7 +101,7 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/kcompletion_export.h ${KCompletion_HEADERS} - DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KCompletion COMPONENT Devel + DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/KCompletion COMPONENT Devel ) if(BUILD_DESIGNERPLUGIN) @@ -136,7 +136,7 @@ endif() include(ECMGeneratePriFile) -ecm_generate_pri_file(BASE_NAME KCompletion LIB_NAME KF5Completion DEPS "widgets" FILENAME_VAR PRI_FILENAME INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/KCompletion) +ecm_generate_pri_file(BASE_NAME KCompletion LIB_NAME KF5Completion DEPS "widgets" FILENAME_VAR PRI_FILENAME INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF}/KCompletion) install(FILES ${PRI_FILENAME} DESTINATION ${ECM_MKSPECS_INSTALL_DIR}) ecm_qt_install_logging_categories( diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/src/kcombobox.cpp new/kcompletion-5.90.0/src/kcombobox.cpp --- old/kcompletion-5.89.0/src/kcombobox.cpp 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/src/kcombobox.cpp 2022-01-01 13:26:48.000000000 +0100 @@ -21,13 +21,13 @@ Q_Q(KComboBox); } -void KComboBoxPrivate::_k_lineEditDeleted() +void KComboBoxPrivate::slotLineEditDeleted(QLineEdit *sender) { Q_Q(KComboBox); // yes, we need those ugly casts due to the multiple inheritance - // sender() is guaranteed to be a KLineEdit (see the connect() to the + // "sender" is guaranteed to be a KLineEdit (see the connect() to the // destroyed() signal - const KCompletionBase *base = static_cast<const KCompletionBase *>(static_cast<const KLineEdit *>(q->sender())); + const KCompletionBase *base = static_cast<const KCompletionBase *>(static_cast<const KLineEdit *>(sender)); // is it our delegate, that is destroyed? if (base == q->delegate()) { @@ -57,6 +57,8 @@ KComboBox::~KComboBox() { + Q_D(KComboBox); + disconnect(d->m_klineEditConnection); } bool KComboBox::contains(const QString &text) const @@ -296,7 +298,9 @@ // line edit without us noticing. And KCompletionBase::delegate would // be a dangling pointer then, so prevent that. Note: only do this // when it is a KLineEdit! - connect(edit, SIGNAL(destroyed()), SLOT(_k_lineEditDeleted())); + d->m_klineEditConnection = connect(edit, &QObject::destroyed, this, [d, edit]() { + d->slotLineEditDeleted(edit); + }); connect(d->klineEdit, &KLineEdit::returnKeyPressed, this, qOverload<const QString &>(&KComboBox::returnPressed)); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/src/kcombobox.h new/kcompletion-5.90.0/src/kcombobox.h --- old/kcompletion-5.89.0/src/kcombobox.h 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/src/kcombobox.h 2022-01-01 13:26:48.000000000 +0100 @@ -540,8 +540,6 @@ Q_DECLARE_PRIVATE(KComboBox) std::unique_ptr<KComboBoxPrivate> const d_ptr; // KF6 TODO: change private d_ptr to protected d_ptr, remove friend - - Q_PRIVATE_SLOT(d_func(), void _k_lineEditDeleted()) }; #endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/src/kcombobox_p.h new/kcompletion-5.90.0/src/kcombobox_p.h --- old/kcompletion-5.89.0/src/kcombobox_p.h 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/src/kcombobox_p.h 2022-01-01 13:26:48.000000000 +0100 @@ -34,13 +34,14 @@ */ void init(); - void _k_lineEditDeleted(); + void slotLineEditDeleted(QLineEdit *sender); KComboBox *const q_ptr; KLineEdit *klineEdit = nullptr; bool trapReturnKey = false; QPointer<QMenu> contextMenu; + QMetaObject::Connection m_klineEditConnection; }; #endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/src/kcompletion.cpp new/kcompletion-5.90.0/src/kcompletion.cpp --- old/kcompletion-5.89.0/src/kcompletion.cpp 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/src/kcompletion.cpp 2022-01-01 13:26:48.000000000 +0100 @@ -258,7 +258,7 @@ } // add 0x0-item as delimiter with evtl. weight - node = node->insert(0x0, true); + node = node->insert(QChar(0x0), true); if (weighted) { node->confirm(weight - 1); } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/src/klineedit.cpp new/kcompletion-5.90.0/src/klineedit.cpp --- old/kcompletion-5.89.0/src/klineedit.cpp 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/src/klineedit.cpp 2022-01-01 13:26:48.000000000 +0100 @@ -1213,6 +1213,14 @@ return true; } +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) + constexpr int ctrlE = QKeyCombination(Qt::CTRL | Qt::Key_E).toCombined(); + constexpr int ctrlU = QKeyCombination(Qt::CTRL | Qt::Key_U).toCombined(); +#else + constexpr int ctrlE = Qt::CTRL | Qt::Key_E; + constexpr int ctrlU = Qt::CTRL | Qt::Key_U; +#endif + // Override all the text manupilation accelerators... if (KStandardShortcut::copy().contains(key)) { return true; @@ -1242,7 +1250,7 @@ // but doesn't dare force as "stronger than kaction shortcuts"... else if (e->matches(QKeySequence::SelectAll)) { return true; - } else if (qApp->platformName() == QLatin1String("xcb") && (key == (Qt::CTRL | Qt::Key_E) || key == (Qt::CTRL | Qt::Key_U))) { + } else if (qApp->platformName() == QLatin1String("xcb") && (key == ctrlE || key == ctrlU)) { return true; } @@ -1330,13 +1338,17 @@ void KLineEdit::setCompletionObject(KCompletion *comp, bool handle) { + Q_D(class KLineEdit); + KCompletion *oldComp = compObj(); if (oldComp && handleSignals()) { - disconnect(oldComp, SIGNAL(matches(QStringList)), this, SLOT(setCompletedItems(QStringList))); + disconnect(d->m_matchesConnection); } if (comp && handle) { - connect(comp, SIGNAL(matches(QStringList)), this, SLOT(setCompletedItems(QStringList))); + d->m_matchesConnection = connect(comp, &KCompletion::matches, this, [this](const QStringList &list) { + setCompletedItems(list); + }); } KCompletionBase::setCompletionObject(comp, handle); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/src/klineedit_p.h new/kcompletion-5.90.0/src/klineedit_p.h --- old/kcompletion-5.89.0/src/klineedit_p.h 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/src/klineedit_p.h 2022-01-01 13:26:48.000000000 +0100 @@ -60,6 +60,7 @@ QString userText; QString lastStyleClass; + QMetaObject::Connection m_matchesConnection; KCompletionBox *completionBox; LineEditUrlDropEventFilter *urlDropEventFilter; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/tests/CMakeLists.txt new/kcompletion-5.90.0/tests/CMakeLists.txt --- old/kcompletion-5.89.0/tests/CMakeLists.txt 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/tests/CMakeLists.txt 2022-01-01 13:26:48.000000000 +0100 @@ -3,17 +3,17 @@ include(ECMMarkAsTest) -find_package(Qt5Test ${REQUIRED_QT_VERSION} CONFIG QUIET) +find_package(Qt${QT_MAJOR_VERSION}Test ${REQUIRED_QT_VERSION} CONFIG QUIET) -if(NOT Qt5Test_FOUND) - message(STATUS "Qt5Test not found, manual tests will not be built.") +if(NOT Qt${QT_MAJOR_VERSION}Test_FOUND) + message(STATUS "Qt${QT_MAJOR_VERSION}Test not found, manual tests will not be built.") return() endif() macro(kcompletion_executable_tests) foreach(_testname ${ARGN}) add_executable(${_testname} ${_testname}.cpp) - target_link_libraries(${_testname} Qt5::Test Qt5::Widgets KF5::Completion KF5::ConfigCore) + target_link_libraries(${_testname} Qt${QT_MAJOR_VERSION}::Test Qt${QT_MAJOR_VERSION}::Widgets KF5::Completion KF5::ConfigCore) ecm_mark_as_test(${_testname}) endforeach(_testname) endmacro() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/tests/kcomboboxtest.cpp new/kcompletion-5.90.0/tests/kcomboboxtest.cpp --- old/kcompletion-5.89.0/tests/kcomboboxtest.cpp 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/tests/kcomboboxtest.cpp 2022-01-01 13:26:48.000000000 +0100 @@ -156,14 +156,15 @@ void KComboBoxTest::connectComboSignals(QComboBox *combo) { - QObject::connect(combo, SIGNAL(activated(int)), SLOT(slotActivated(int))); - QObject::connect(combo, SIGNAL(activated(QString)), SLOT(slotActivated(QString))); - QObject::connect(combo, SIGNAL(currentIndexChanged(int)), SLOT(slotCurrentIndexChanged(int))); - QObject::connect(combo, SIGNAL(currentIndexChanged(QString)), SLOT(slotCurrentIndexChanged(QString))); -#if KCOMPLETION_BUILD_DEPRECATED_SINCE(5, 81) - QObject::connect(combo, SIGNAL(returnPressed()), SLOT(slotReturnPressed())); -#endif - QObject::connect(combo, SIGNAL(returnPressed(QString)), SLOT(slotReturnPressed(QString))); + QObject::connect(combo, qOverload<int>(&QComboBox::activated), this, &KComboBoxTest::slotActivated); + QObject::connect(combo, &QComboBox::textActivated, this, &KComboBoxTest::slotTextActivated); + + QObject::connect(combo, qOverload<int>(&QComboBox::currentIndexChanged), this, &KComboBoxTest::slotCurrentIndexChanged); + QObject::connect(combo, qOverload<int>(&QComboBox::currentIndexChanged), this, [this, combo](const int index) { + slotCurrentTextChanged(combo->itemText(index)); + }); + + QObject::connect(combo, &QComboBox::textActivated, this, qOverload<const QString &>(&KComboBoxTest::slotReturnPressed)); } void KComboBoxTest::slotDisable() @@ -202,7 +203,7 @@ qDebug() << qPrintable(sender()->objectName()) << ", index:" << index; } -void KComboBoxTest::slotCurrentIndexChanged(const QString &item) +void KComboBoxTest::slotCurrentTextChanged(const QString &item) { qDebug() << qPrintable(sender()->objectName()) << ", item:" << item; } @@ -212,7 +213,7 @@ qDebug() << "Activated Combo:" << qPrintable(sender()->objectName()) << ", index:" << index; } -void KComboBoxTest::slotActivated(const QString &item) +void KComboBoxTest::slotTextActivated(const QString &item) { qDebug() << "Activated Combo:" << qPrintable(sender()->objectName()) << ", item:" << item; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcompletion-5.89.0/tests/kcomboboxtest.h new/kcompletion-5.90.0/tests/kcomboboxtest.h --- old/kcompletion-5.89.0/tests/kcomboboxtest.h 2021-12-04 19:32:34.000000000 +0100 +++ new/kcompletion-5.90.0/tests/kcomboboxtest.h 2022-01-01 13:26:48.000000000 +0100 @@ -28,9 +28,9 @@ #endif void slotReturnPressed(const QString &); void slotActivated(int); - void slotActivated(const QString &); + void slotTextActivated(const QString &); void slotCurrentIndexChanged(int); - void slotCurrentIndexChanged(const QString &); + void slotCurrentTextChanged(const QString &); private: void connectComboSignals(QComboBox *combo);
