[SCM] muon packaging branch, kubuntu_vivid_archive, updated. fa5f521bc71b6dfa2f760ad6478666e1ea215cc7

Jonathan Riddell jriddell-guest at moszumanska.debian.org
Tue Apr 28 14:11:33 UTC 2015


Gitweb-URL: http://git.debian.org/?p=pkg-kde/plasma/muon.git;a=commitdiff;h=fa5f521

The following commit has been merged in the kubuntu_vivid_archive branch:
commit fa5f521bc71b6dfa2f760ad6478666e1ea215cc7
Author: Jonathan Riddell <jr at jriddell.org>
Date:   Tue Apr 28 16:11:29 2015 +0200

    Add upstream_notifications.diff from upstream to prevent repeated notification popups LP: #1449583
---
 debian/changelog                           |  7 ++++
 debian/patches/upstream_notifications.diff | 65 ++++++++++++++++++++++++++++++
 2 files changed, 72 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 63953ca..8c38152 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+muon (4:5.2.2-1-0ubuntu4.1) vivid; urgency=medium
+
+  * Add upstream_notifications.diff from upstream to prevent repeated
+    notification popups LP: #1449583
+
+ -- Jonathan Riddell <jriddell at ubuntu.com>  Tue, 28 Apr 2015 16:10:36 +0200
+
 muon (4:5.2.2-1-0ubuntu4) vivid; urgency=medium
 
   * Add upstream_notifyrc-path.diff to fix install location of notifyrc
diff --git a/debian/patches/upstream_notifications.diff b/debian/patches/upstream_notifications.diff
new file mode 100644
index 0000000..166a60c
--- /dev/null
+++ b/debian/patches/upstream_notifications.diff
@@ -0,0 +1,65 @@
+diff --git a/libmuon/backends/ApplicationBackend/ApplicationNotifier.cpp b/libmuon/backends/ApplicationBackend/ApplicationNotifier.cpp
+index 9ec3612..0ae2667 100644
+--- a/libmuon/backends/ApplicationBackend/ApplicationNotifier.cpp
++++ b/libmuon/backends/ApplicationBackend/ApplicationNotifier.cpp
+@@ -87,7 +87,7 @@ void ApplicationNotifier::checkUpgradeFinished(int exitStatus)
+                                                 i18n("System update available!"),
+                                                 i18nc("Notification when a new version of Kubuntu is available",
+                                                       "A new version of Kubuntu is available"),
+-                                                QIcon::fromTheme("svn-update").pixmap(KIconLoader::SizeMedium),
++                                                QStringLiteral("system-software-update"),
+                                                 nullptr,
+                                                 KNotification::CloseOnTimeout,
+                                                 "muonapplicationnotifier");
+@@ -135,14 +135,22 @@ void ApplicationNotifier::parseUpdateInfo()
+         QByteArray updatesString = line.left(eqpos);
+         QByteArray securityString = line.right(line.size() - eqpos - 1);
+         
+-        m_securityUpdates = securityString.toInt();
+-        m_normalUpdates = updatesString.toInt() - m_securityUpdates;
++        int securityUpdates = securityString.toInt();
++        setUpdates(updatesString.toInt() - m_securityUpdates, securityUpdates);
+     }
+-    emit foundUpdates();
+     
+     m_checkingForUpdates = false;
+ }
+ 
++void ApplicationNotifier::setUpdates(int normal, int security)
++{
++    if (m_normalUpdates != normal || security != m_securityUpdates) {
++        m_normalUpdates = normal;
++        m_securityUpdates = security;
++        emit foundUpdates();
++    }
++}
++
+ bool ApplicationNotifier::isSystemUpToDate() const
+ {
+     return (m_securityUpdates+m_normalUpdates)==0;
+diff --git a/libmuon/backends/ApplicationBackend/ApplicationNotifier.h b/libmuon/backends/ApplicationBackend/ApplicationNotifier.h
+index 1c281e6..00192d9 100644
+--- a/libmuon/backends/ApplicationBackend/ApplicationNotifier.h
++++ b/libmuon/backends/ApplicationBackend/ApplicationNotifier.h
+@@ -49,6 +49,8 @@ private slots:
+     void init();
+ 
+ private:
++    void setUpdates(int normal, int security);
++
+     QProcess *m_checkerProcess;
+     QProcess *m_updateCheckerProcess;
+     bool m_checkingForUpdates;
+diff --git a/notifier/MuonNotifier.cpp b/notifier/MuonNotifier.cpp
+index 05927bc..e3ca913 100644
+--- a/notifier/MuonNotifier.cpp
++++ b/notifier/MuonNotifier.cpp
+@@ -80,7 +80,7 @@ void MuonNotifier::updateStatusNotifier()
+ //         m_statusNotifier->setToolTip(iconName(), msg, i18n("A system update is recommended"));
+ //         m_statusNotifier->setStatus(KStatusNotifierItem::Active);
+ 
+-        KNotification::event("Update", i18n("System update available"), msg, QIcon::fromTheme("svn-update").pixmap(KIconLoader::SizeMedium), nullptr, KNotification::CloseOnTimeout, "muonabstractnotifier");
++        KNotification::event("Update", i18n("System update available"), msg, QStringLiteral("system-software-update"), nullptr, KNotification::CloseOnTimeout, "muonabstractnotifier");
+     } else {
+ //         m_statusNotifier->setStatus(KStatusNotifierItem::Passive);
+ //         m_s:tatusNotifier->setToolTip(QString(), message(), i18n("Your system is up-to-date"));

-- 
muon packaging



More information about the pkg-kde-commits mailing list