[apper/f18] pull in a few upstream fixes, including followup for kde#302786

Rex Dieter rdieter at fedoraproject.org
Wed Jan 9 17:07:12 UTC 2013


commit 66beaf03ea446fb008f68ab5061ed845df249348
Author: Rex Dieter <rdieter at math.unl.edu>
Date:   Wed Jan 9 11:07:39 2013 -0600

    pull in a few upstream fixes, including followup for kde#302786

 ...hen-using-double-click-on-the-desktop-BUG.patch |    3 +-
 ...apperd-to-watch-a-transaction-when-it-s-j.patch |   26 ++++++++++
 ...CPU-usage-by-not-setting-an-initial-state.patch |   26 ++++++++++
 0004-Adds-a-Help-menu-to-Apper-BUG-293440.patch    |   53 ++++++++++++++++++++
 ...connection-caused-by-a-fix-for-BUG-302786.patch |   25 +++++++++
 apper.spec                                         |   22 +++++++-
 6 files changed, 152 insertions(+), 3 deletions(-)
---
diff --git a/0001-Fixed-bug-when-using-double-click-on-the-desktop-BUG.patch b/0001-Fixed-bug-when-using-double-click-on-the-desktop-BUG.patch
index 2d4c33e..9c086ec 100644
--- a/0001-Fixed-bug-when-using-double-click-on-the-desktop-BUG.patch
+++ b/0001-Fixed-bug-when-using-double-click-on-the-desktop-BUG.patch
@@ -1,7 +1,8 @@
 From 808ed3e2cc55415fcff70686afdacf1a8190db72 Mon Sep 17 00:00:00 2001
 From: Daniel Nicoletti <dantti12 at gmail.com>
 Date: Tue, 8 Jan 2013 20:03:31 -0200
-Subject: [PATCH] Fixed bug when using double click on the desktop, BUG:302786
+Subject: [PATCH 1/5] Fixed bug when using double click on the desktop,
+ BUG:302786
 
 ---
  ApperKCM/ApperKCM.cpp | 2 +-
diff --git a/0002-Don-t-tell-apperd-to-watch-a-transaction-when-it-s-j.patch b/0002-Don-t-tell-apperd-to-watch-a-transaction-when-it-s-j.patch
new file mode 100644
index 0000000..14d5c63
--- /dev/null
+++ b/0002-Don-t-tell-apperd-to-watch-a-transaction-when-it-s-j.patch
@@ -0,0 +1,26 @@
+From 7fb3d6dff1705e9a49953e775cadcf22c5bd2699 Mon Sep 17 00:00:00 2001
+From: Daniel Nicoletti <dantti12 at gmail.com>
+Date: Wed, 9 Jan 2013 12:49:29 -0200
+Subject: [PATCH 2/5] Don't tell apperd to watch a transaction when it's just
+ simulating
+
+---
+ libapper/PkTransaction.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libapper/PkTransaction.cpp b/libapper/PkTransaction.cpp
+index c81f8bf..9ab949b 100644
+--- a/libapper/PkTransaction.cpp
++++ b/libapper/PkTransaction.cpp
+@@ -395,7 +395,7 @@ void PkTransaction::slotChanged()
+     }
+ 
+     QDBusObjectPath _tid = tid();
+-    if (d->tid != _tid) {
++    if (d->tid != _tid && !(d->flags & Transaction::TransactionFlagSimulate)) {
+         // if the transaction changed and
+         // the user wants the watcher send the tid
+         QDBusMessage message;
+-- 
+1.8.1
+
diff --git a/0003-Reduce-the-CPU-usage-by-not-setting-an-initial-state.patch b/0003-Reduce-the-CPU-usage-by-not-setting-an-initial-state.patch
new file mode 100644
index 0000000..1323846
--- /dev/null
+++ b/0003-Reduce-the-CPU-usage-by-not-setting-an-initial-state.patch
@@ -0,0 +1,26 @@
+From 2990121024410801e9767871297f369512cf0c72 Mon Sep 17 00:00:00 2001
+From: Daniel Nicoletti <dantti12 at gmail.com>
+Date: Wed, 9 Jan 2013 13:02:59 -0200
+Subject: [PATCH 3/5] Reduce the CPU usage by not setting an initial state when
+ starting (makes BusyCurso not run which eats CPU)
+
+---
+ plasmoid/package/contents/ui/main.qml | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/plasmoid/package/contents/ui/main.qml b/plasmoid/package/contents/ui/main.qml
+index 222ce97..89bcef9 100644
+--- a/plasmoid/package/contents/ui/main.qml
++++ b/plasmoid/package/contents/ui/main.qml
+@@ -23,7 +23,7 @@ import org.packagekit 0.1 as PackageKit
+ FocusScope {
+     id: root
+ 
+-    state: "BUSY"
++    state: ""
+ 
+     property int minimumHeight: 320
+     property int minimumWidth: 370
+-- 
+1.8.1
+
diff --git a/0004-Adds-a-Help-menu-to-Apper-BUG-293440.patch b/0004-Adds-a-Help-menu-to-Apper-BUG-293440.patch
new file mode 100644
index 0000000..d209927
--- /dev/null
+++ b/0004-Adds-a-Help-menu-to-Apper-BUG-293440.patch
@@ -0,0 +1,53 @@
+From a7d3614e0cc9bb4dcd0720281f8760578a93465c Mon Sep 17 00:00:00 2001
+From: Daniel Nicoletti <dantti12 at gmail.com>
+Date: Wed, 9 Jan 2013 13:50:59 -0200
+Subject: [PATCH 4/5] Adds a Help menu to Apper BUG 293440
+
+---
+ Apper/MainUi.cpp      | 3 ++-
+ ApperKCM/ApperKCM.cpp | 8 ++++++++
+ 2 files changed, 10 insertions(+), 1 deletion(-)
+
+diff --git a/Apper/MainUi.cpp b/Apper/MainUi.cpp
+index 587d75a..31c2092 100644
+--- a/Apper/MainUi.cpp
++++ b/Apper/MainUi.cpp
+@@ -39,7 +39,8 @@ MainUi::MainUi(QWidget *parent)
+     // Set Apply and Cancel buttons
+     setButtons(KDialog::Apply /*| KDialog::Help*/ | KDialog::Default | KDialog::Reset);
+ 
+-    KPageWidgetItem *page = addModule("kcm_apper.desktop");
++    KPageWidgetItem *page = addModule(QLatin1String("kcm_apper.desktop"),
++                                      QStringList() << QLatin1String("apper"));
+     if (page) {
+         KCModuleProxy *proxy = static_cast<KCModuleProxy*>(page->widget());
+         if (proxy) {
+diff --git a/ApperKCM/ApperKCM.cpp b/ApperKCM/ApperKCM.cpp
+index 14a5cd6..a6677b0 100644
+--- a/ApperKCM/ApperKCM.cpp
++++ b/ApperKCM/ApperKCM.cpp
+@@ -31,6 +31,7 @@
+ #include <KMessageBox>
+ #include <KFileItemDelegate>
+ #include <KMenu>
++#include <KHelpMenu>
+ #include <KTabBar>
+ 
+ #include <PackageModel.h>
+@@ -221,6 +222,13 @@ ApperKCM::ApperKCM(QWidget *parent, const QVariantList &args) :
+     connect(signalMapper, SIGNAL(mapped(QString)),
+             this, SLOT(setPage(QString)));
+ 
++    // Only show help menu if not on System Settings
++    if (!args.isEmpty()) {
++        // adds the help menu
++        KHelpMenu *helpMenu = new KHelpMenu(this);
++        menu->addMenu(helpMenu->menu());
++    }
++
+     // Make sure the search bar is visible
+     ui->stackedWidgetBar->setCurrentIndex(BAR_SEARCH);
+ }
+-- 
+1.8.1
+
diff --git a/0005-Fix-a-connection-caused-by-a-fix-for-BUG-302786.patch b/0005-Fix-a-connection-caused-by-a-fix-for-BUG-302786.patch
new file mode 100644
index 0000000..ef1f74f
--- /dev/null
+++ b/0005-Fix-a-connection-caused-by-a-fix-for-BUG-302786.patch
@@ -0,0 +1,25 @@
+From decb93370d447c368cf2255c6b2c7f4502844cc8 Mon Sep 17 00:00:00 2001
+From: Daniel Nicoletti <dantti12 at gmail.com>
+Date: Wed, 9 Jan 2013 14:48:49 -0200
+Subject: [PATCH 5/5] Fix a connection caused by a fix for BUG:302786
+
+---
+ ApperKCM/ApperKCM.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/ApperKCM/ApperKCM.cpp b/ApperKCM/ApperKCM.cpp
+index a6677b0..b408fe9 100644
+--- a/ApperKCM/ApperKCM.cpp
++++ b/ApperKCM/ApperKCM.cpp
+@@ -110,7 +110,7 @@ ApperKCM::ApperKCM(QWidget *parent, const QVariantList &args) :
+     toolBar->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
+ 
+     connect(ui->browseView, SIGNAL(categoryActivated(QModelIndex)),
+-            this, SLOT(on_homeView_clicked(QModelIndex)));
++            this, SLOT(on_homeView_activated(QModelIndex)));
+ 
+     QMenu *findMenu = new QMenu(this);
+     // find is just a generic name in case we don't have any search method
+-- 
+1.8.1
+
diff --git a/apper.spec b/apper.spec
index bb7aa12..171d2b1 100644
--- a/apper.spec
+++ b/apper.spec
@@ -7,7 +7,7 @@
 
 Name:    apper
 Version: 0.8.0
-Release: 1%{?dist}
+Release: 2%{?dist}
 Summary: KDE interface for PackageKit
 
 License: GPLv2+
@@ -24,12 +24,17 @@ Source10: 01-fedora-apper-updater.js
 
 ## upstream patches
 Patch101: 0001-Fixed-bug-when-using-double-click-on-the-desktop-BUG.patch
+Patch102: 0002-Don-t-tell-apperd-to-watch-a-transaction-when-it-s-j.patch
+Patch103: 0003-Reduce-the-CPU-usage-by-not-setting-an-initial-state.patch
+Patch104: 0004-Adds-a-Help-menu-to-Apper-BUG-293440.patch
+Patch105: 0005-Fix-a-connection-caused-by-a-fix-for-BUG-302786.patch
 
 Obsoletes: kpackagekit < 0.7.0
 Provides:  kpackagekit = %{version}-%{release}
 # required because gnome-packagekit provides exactly the same interface
 Provides: PackageKit-session-service
 
+BuildRequires: git-core
 BuildRequires: chrpath 
 BuildRequires: desktop-file-utils
 BuildRequires: gettext
@@ -53,7 +58,17 @@ KDE interface for PackageKit.
 
 %prep
 %setup -q 
-%patch101 -p1 -b .0001
+
+git init
+if [ -z "$GIT_COMMITTER_NAME" ]; then
+git config user.email "kde at lists.fedoraproject.org"
+git config user.name "Fedora KDE SIG"
+fi
+git add .
+git commit -a -q -m "%{version} baseline."
+
+# Apply all the patches
+git am -p1 %{patches} < /dev/null
 
 
 %build
@@ -131,6 +146,9 @@ fi
 
 
 %changelog
+* Wed Jan 09 2013 Rex Dieter <rdieter at fedoraproject.org> 0.8.0-2
+- pull in a few upstream fixes, including followup for kde#302786
+
 * Tue Jan 08 2013 Rex Dieter <rdieter at fedoraproject.org> 0.8.0-1
 - 0.8.0
 


More information about the scm-commits mailing list