Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package kidletime for openSUSE:Factory 
checked in at 2022-03-14 19:34:31
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/kidletime (Old)
 and      /work/SRC/openSUSE:Factory/.kidletime.new.25692 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "kidletime"

Mon Mar 14 19:34:31 2022 rev:100 rq:961251 version:5.92.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/kidletime/kidletime.changes      2022-02-24 
18:21:50.706684081 +0100
+++ /work/SRC/openSUSE:Factory/.kidletime.new.25692/kidletime.changes   
2022-03-14 19:35:57.574046760 +0100
@@ -1,0 +2,10 @@
+Mon Mar  7 09:26:58 UTC 2022 - Christophe Giboudeaux <[email protected]>
+
+- Update to 5.92.0
+  * New feature release
+  * For more details please see:
+  * https://kde.org/announcements/frameworks/5/5.92.0
+- Changes since 5.91.0:
+  * General code clean-up
+
+-------------------------------------------------------------------

Old:
----
  kidletime-5.91.0.tar.xz
  kidletime-5.91.0.tar.xz.sig

New:
----
  kidletime-5.92.0.tar.xz
  kidletime-5.92.0.tar.xz.sig

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ kidletime.spec ++++++
--- /var/tmp/diff_new_pack.m85qSn/_old  2022-03-14 19:35:58.202047513 +0100
+++ /var/tmp/diff_new_pack.m85qSn/_new  2022-03-14 19:35:58.206047518 +0100
@@ -17,7 +17,7 @@
 
 
 %define lname   libKF5IdleTime5
-%define _tar_path 5.91
+%define _tar_path 5.92
 # Full KF5 version (e.g. 5.33.0)
 %{!?_kf5_version: %global _kf5_version %{version}}
 # Last major and minor KF5 version (e.g. 5.33)
@@ -25,7 +25,7 @@
 # Only needed for the package signature condition
 %bcond_without released
 Name:           kidletime
-Version:        5.91.0
+Version:        5.92.0
 Release:        0
 Summary:        User and system idle time reporting singleton
 License:        LGPL-2.1-or-later


++++++ kidletime-5.91.0.tar.xz -> kidletime-5.92.0.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kidletime-5.91.0/CMakeLists.txt 
new/kidletime-5.92.0/CMakeLists.txt
--- old/kidletime-5.91.0/CMakeLists.txt 2022-02-05 16:14:06.000000000 +0100
+++ new/kidletime-5.92.0/CMakeLists.txt 2022-03-05 12:14:51.000000000 +0100
@@ -1,11 +1,11 @@
 cmake_minimum_required(VERSION 3.16)
 
-set(KF_VERSION "5.91.0") # handled by release scripts
+set(KF_VERSION "5.92.0") # handled by release scripts
 project(KIdleTime VERSION ${KF_VERSION})
 
 # ECM setup
 include(FeatureSummary)
-find_package(ECM 5.91.0  NO_MODULE)
+find_package(ECM 5.92.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/kidletime-5.91.0/src/abstractsystempoller.h 
new/kidletime-5.92.0/src/abstractsystempoller.h
--- old/kidletime-5.91.0/src/abstractsystempoller.h     2022-02-05 
16:14:06.000000000 +0100
+++ new/kidletime-5.92.0/src/abstractsystempoller.h     2022-03-05 
12:14:51.000000000 +0100
@@ -28,7 +28,10 @@
 public Q_SLOTS:
     virtual void addTimeout(int nextTimeout) = 0;
     virtual void removeTimeout(int nextTimeout) = 0;
-    virtual QList<int> timeouts() const = 0;
+
+    // TODO KF6: Make it a public method
+    virtual QList<int> timeouts() const = 0; // 
clazy:exclude=const-signal-or-slot
+
     virtual int forcePollRequest() = 0;
     virtual void catchIdleEvent() = 0;
     virtual void stopCatchingIdleEvents() = 0;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kidletime-5.91.0/src/kidletime.cpp 
new/kidletime-5.92.0/src/kidletime.cpp
--- old/kidletime-5.91.0/src/kidletime.cpp      2022-02-05 16:14:06.000000000 
+0100
+++ new/kidletime-5.92.0/src/kidletime.cpp      2022-03-05 12:14:51.000000000 
+0100
@@ -134,15 +134,20 @@
 {
     Q_D(KIdleTime);
 
-    if (!d->associations.contains(identifier) || !d->poller) {
+    const auto it = d->associations.constFind(identifier);
+    if (it == d->associations.cend() || !d->poller) {
         return;
     }
 
-    int msec = d->associations[identifier];
+    const int msec = it.value();
 
-    d->associations.remove(identifier);
+    d->associations.erase(it);
 
-    if (!d->associations.values().contains(msec)) {
+    const bool isFound = std::any_of(d->associations.cbegin(), 
d->associations.cend(), [msec](int i) {
+        return i == msec;
+    });
+
+    if (!isFound) {
         d->poller.data()->removeTimeout(msec);
     }
 }
@@ -151,25 +156,24 @@
 {
     Q_D(KIdleTime);
 
-    QHash<int, int>::iterator i = d->associations.begin();
-    QSet<int> removed;
-    removed.reserve(d->associations.size());
-
-    while (i != d->associations.end()) {
-        int msec = d->associations[i.key()];
+    std::vector<int> removed;
 
-        i = d->associations.erase(i);
-
-        if (!removed.contains(msec) && d->poller) {
+    for (auto it = d->associations.cbegin(); it != d->associations.cend(); 
++it) {
+        const int msec = it.value();
+        const bool alreadyIns = std::find(removed.cbegin(), removed.cend(), 
msec) != removed.cend();
+        if (!alreadyIns && d->poller) {
+            removed.push_back(msec);
             d->poller.data()->removeTimeout(msec);
-            removed.insert(msec);
         }
     }
+
+    d->associations.clear();
 }
 
 static QStringList pluginCandidates()
 {
     QStringList ret;
+
     const QStringList libPath = QCoreApplication::libraryPaths();
     for (const QString &path : libPath) {
 #ifdef Q_OS_MACOS
@@ -180,10 +184,15 @@
         if (!pluginDir.exists()) {
             continue;
         }
-        for (const QString &entry : pluginDir.entryList(QDir::Files | 
QDir::NoDotAndDotDot)) {
+
+        const auto entries = pluginDir.entryList(QDir::Files | 
QDir::NoDotAndDotDot);
+
+        ret.reserve(ret.size() + entries.size());
+        for (const QString &entry : entries) {
             ret << pluginDir.absoluteFilePath(entry);
         }
     }
+
     return ret;
 }
 
@@ -279,13 +288,12 @@
 {
     Q_Q(KIdleTime);
 
-    if (associations.values().contains(msec)) {
-        const auto listKeys = associations.keys(msec);
-        for (int key : listKeys) {
+    for (auto it = associations.cbegin(); it != associations.cend(); ++it) {
+        if (it.value() == msec) {
 #if KIDLETIME_BUILD_DEPRECATED_SINCE(5, 76)
-            Q_EMIT q->timeoutReached(key);
+            Q_EMIT q->timeoutReached(it.key());
 #endif
-            Q_EMIT q->timeoutReached(key, msec);
+            Q_EMIT q->timeoutReached(it.key(), msec);
         }
     }
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kidletime-5.91.0/src/kidletime.h 
new/kidletime-5.92.0/src/kidletime.h
--- old/kidletime-5.91.0/src/kidletime.h        2022-02-05 16:14:06.000000000 
+0100
+++ new/kidletime-5.92.0/src/kidletime.h        2022-03-05 12:14:51.000000000 
+0100
@@ -180,7 +180,7 @@
      * @deprecated Since 5.76, use only timeoutReached(int identifier, int 
msec)
      */
     KIDLETIME_DEPRECATED_VERSION(5, 76, "Use only timeoutReached(int 
identifier, int msec)")
-    void timeoutReached(int identifier);
+    void timeoutReached(int identifier); // clazy:exclude=overloaded-signal
 #endif
 
     /**
@@ -196,7 +196,7 @@
      * @see addIdleTimeout
      * @see removeIdleTimeout
      */
-    void timeoutReached(int identifier, int msec);
+    void timeoutReached(int identifier, int msec); // 
clazy:exclude=overloaded-signal
 
 private:
     KIdleTime();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/kidletime-5.91.0/src/plugins/xsync/xsyncbasedpoller.h 
new/kidletime-5.92.0/src/plugins/xsync/xsyncbasedpoller.h
--- old/kidletime-5.91.0/src/plugins/xsync/xsyncbasedpoller.h   2022-02-05 
16:14:06.000000000 +0100
+++ new/kidletime-5.92.0/src/plugins/xsync/xsyncbasedpoller.h   2022-03-05 
12:14:51.000000000 +0100
@@ -36,10 +36,12 @@
 
     bool xcbEvent(xcb_generic_event_t *event);
 
+    QList<int> timeouts() const override;
+
 public Q_SLOTS:
     void addTimeout(int nextTimeout) override;
     void removeTimeout(int nextTimeout) override;
-    QList<int> timeouts() const override;
+
     int forcePollRequest() override;
     void catchIdleEvent() override;
     void stopCatchingIdleEvents() override;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/kidletime-5.91.0/src/widgetbasedpoller.h 
new/kidletime-5.92.0/src/widgetbasedpoller.h
--- old/kidletime-5.91.0/src/widgetbasedpoller.h        2022-02-05 
16:14:06.000000000 +0100
+++ new/kidletime-5.92.0/src/widgetbasedpoller.h        2022-03-05 
12:14:51.000000000 +0100
@@ -27,13 +27,15 @@
     bool setUpPoller() override;
     void unloadPoller() override;
 
+    QList<int> timeouts() const override;
+
 protected:
     bool eventFilter(QObject *object, QEvent *event) override;
 
 public Q_SLOTS:
     void addTimeout(int nextTimeout) override;
     void removeTimeout(int nextTimeout) override;
-    QList<int> timeouts() const override;
+
     int forcePollRequest() override;
     void catchIdleEvent() override;
     void stopCatchingIdleEvents() override;

Reply via email to