Hello community, here is the log from the commit of package kitemmodels for openSUSE:Leap:15.2 checked in at 2020-04-21 19:05:18 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Leap:15.2/kitemmodels (Old) and /work/SRC/openSUSE:Leap:15.2/.kitemmodels.new.2738 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "kitemmodels" Tue Apr 21 19:05:18 2020 rev:63 rq:794319 version:5.69.0 Changes: -------- --- /work/SRC/openSUSE:Leap:15.2/kitemmodels/kitemmodels.changes 2020-03-21 16:44:59.749514396 +0100 +++ /work/SRC/openSUSE:Leap:15.2/.kitemmodels.new.2738/kitemmodels.changes 2020-04-21 19:05:19.375720120 +0200 @@ -1,0 +2,11 @@ +Sun Apr 5 19:45:40 UTC 2020 - Christophe Giboudeaux <[email protected]> + +- Update to 5.69.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/kde-frameworks-5.69.0 +- Changes since 5.68.0: + * [KItemModels/KLinkItemSelectionModelTest] Port QRegExp to QRegularExpression + * [KSortFilterProxyModel QML] Make invalidateFilter public + +------------------------------------------------------------------- Old: ---- kitemmodels-5.68.0.tar.xz kitemmodels-5.68.0.tar.xz.sig New: ---- kitemmodels-5.69.0.tar.xz kitemmodels-5.69.0.tar.xz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ kitemmodels.spec ++++++ --- /var/tmp/diff_new_pack.FIzhES/_old 2020-04-21 19:05:20.115721627 +0200 +++ /var/tmp/diff_new_pack.FIzhES/_new 2020-04-21 19:05:20.115721627 +0200 @@ -17,7 +17,7 @@ %define lname libKF5ItemModels5 -%define _tar_path 5.68 +%define _tar_path 5.69 # Full KF5 version (e.g. 5.33.0) %{!?_kf5_version: %global _kf5_version %{version}} # Last major and minor KF5 version (e.g. 5.33) @@ -26,7 +26,7 @@ # Only needed for the package signature condition %bcond_without lang Name: kitemmodels -Version: 5.68.0 +Version: 5.69.0 Release: 0 Summary: Set of item models extending the Qt model-view framework License: LGPL-2.1-or-later ++++++ kitemmodels-5.68.0.tar.xz -> kitemmodels-5.69.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kitemmodels-5.68.0/CMakeLists.txt new/kitemmodels-5.69.0/CMakeLists.txt --- old/kitemmodels-5.68.0/CMakeLists.txt 2020-03-07 09:52:56.000000000 +0100 +++ new/kitemmodels-5.69.0/CMakeLists.txt 2020-04-05 00:35:55.000000000 +0200 @@ -1,10 +1,10 @@ cmake_minimum_required(VERSION 3.5) -set(KF5_VERSION "5.68.0") # handled by release scripts +set(KF5_VERSION "5.69.0") # handled by release scripts project(KItemModels VERSION ${KF5_VERSION}) include(FeatureSummary) -find_package(ECM 5.68.0 NO_MODULE) +find_package(ECM 5.69.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) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kitemmodels-5.68.0/autotests/klinkitemselectionmodeltest.cpp new/kitemmodels-5.69.0/autotests/klinkitemselectionmodeltest.cpp --- old/kitemmodels-5.68.0/autotests/klinkitemselectionmodeltest.cpp 2020-03-07 09:52:56.000000000 +0100 +++ new/kitemmodels-5.69.0/autotests/klinkitemselectionmodeltest.cpp 2020-04-05 00:35:55.000000000 +0200 @@ -27,7 +27,7 @@ // Init subModel m_subModel = new QSortFilterProxyModel; - m_subModel->setFilterRegExp(QRegExp(QStringLiteral("^[5-9]"))); + m_subModel->setFilterRegularExpression(QRegularExpression(QStringLiteral("^[5-9]"))); m_subModel->setSourceModel(m_mainModel); m_subSelectionModel = new KLinkItemSelectionModel(m_subModel, m_mainSelectionModel); } @@ -185,7 +185,7 @@ { QSortFilterProxyModel additionalProxy; - additionalProxy.setFilterRegExp(QRegExp(QStringLiteral("^[3-9]"))); + additionalProxy.setFilterRegularExpression(QRegularExpression(QStringLiteral("^[3-9]"))); additionalProxy.setSourceModel(m_mainModel); KLinkItemSelectionModel additionalLink; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kitemmodels-5.68.0/autotests/ksortfilterproxymodel_qml.cpp new/kitemmodels-5.69.0/autotests/ksortfilterproxymodel_qml.cpp --- old/kitemmodels-5.68.0/autotests/ksortfilterproxymodel_qml.cpp 2020-03-07 09:52:56.000000000 +0100 +++ new/kitemmodels-5.69.0/autotests/ksortfilterproxymodel_qml.cpp 2020-04-05 00:35:55.000000000 +0200 @@ -61,12 +61,13 @@ "import org.kde.kitemmodels 1.0\n" "KSortFilterProxyModel\n" "{\n" + " property int modulo: 2\n" " sourceModel: KNumberModel {\n" " minimumValue: 1\n" " maximumValue: 10\n" " }\n" " filterRowCallback: function(source_row, source_parent) {\n" - " return sourceModel.data(sourceModel.index(source_row, 0, source_parent), Qt.DisplayRole) % 2 == 1;\n" + " return sourceModel.data(sourceModel.index(source_row, 0, source_parent), Qt.DisplayRole) % modulo == 1;\n" " };\n" "}\n"); QCOMPARE(app.rootObjects().count(), 1); @@ -80,8 +81,27 @@ QCOMPARE(filterModel->data(filterModel->index(2, 0)).toString(), "5"); QCOMPARE(filterModel->data(filterModel->index(3, 0)).toString(), "7"); QCOMPARE(filterModel->data(filterModel->index(4, 0)).toString(), "9"); -} + filterModel->setProperty("modulo", 3); + + // Nothing should change until we call invalidateFilter + QCOMPARE(filterModel->rowCount(), 5); + QCOMPARE(filterModel->data(filterModel->index(0, 0)).toString(), "1"); + QCOMPARE(filterModel->data(filterModel->index(1, 0)).toString(), "3"); + QCOMPARE(filterModel->data(filterModel->index(2, 0)).toString(), "5"); + QCOMPARE(filterModel->data(filterModel->index(3, 0)).toString(), "7"); + QCOMPARE(filterModel->data(filterModel->index(4, 0)).toString(), "9"); + + // Simulate call from QML by going through metaobject rather than calling it directly + const bool invalidateFilterCallOk = QMetaObject::invokeMethod(filterModel, "invalidateFilter"); + QVERIFY(invalidateFilterCallOk); + + QCOMPARE(filterModel->rowCount(), 4); + QCOMPARE(filterModel->data(filterModel->index(0, 0)).toString(), "1"); + QCOMPARE(filterModel->data(filterModel->index(1, 0)).toString(), "4"); + QCOMPARE(filterModel->data(filterModel->index(2, 0)).toString(), "7"); + QCOMPARE(filterModel->data(filterModel->index(3, 0)).toString(), "10"); +} void tst_KSortFilterProxyModelQml::testSortRole_data() { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kitemmodels-5.68.0/src/qml/ksortfilterproxymodel.cpp new/kitemmodels-5.69.0/src/qml/ksortfilterproxymodel.cpp --- old/kitemmodels-5.68.0/src/qml/ksortfilterproxymodel.cpp 2020-03-07 09:52:56.000000000 +0100 +++ new/kitemmodels-5.69.0/src/qml/ksortfilterproxymodel.cpp 2020-04-05 00:35:55.000000000 +0200 @@ -220,3 +220,8 @@ setSortRole(m_sortRole); } } + +void KSortFilterProxyModel::invalidateFilter() +{ + QSortFilterProxyModel::invalidateFilter(); +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kitemmodels-5.68.0/src/qml/ksortfilterproxymodel.h new/kitemmodels-5.69.0/src/qml/ksortfilterproxymodel.h --- old/kitemmodels-5.68.0/src/qml/ksortfilterproxymodel.h 2020-03-07 09:52:56.000000000 +0100 +++ new/kitemmodels-5.69.0/src/qml/ksortfilterproxymodel.h 2020-04-05 00:35:55.000000000 +0200 @@ -122,6 +122,17 @@ void classBegin() override; void componentComplete() override; +public Q_SLOTS: + /** + * Invalidates the current filtering. + * + * This function should be called if you are implementing custom filtering through + * filterRowCallback or filterColumnCallback, and your filter parameters have changed. + * + * @since 5.70 + */ + void invalidateFilter(); + Q_SIGNALS: void filterStringChanged(); void filterRoleChanged();
