[arch-commits] Commit in kdelibs/trunk (PKGBUILD refcount.patch)

Pierre Schmitz pierre at archlinux.org
Fri Aug 29 07:06:14 UTC 2008


    Date: Friday, August 29, 2008 @ 03:06:14
  Author: pierre
Revision: 10431

upgpkg: kdelibs 4.1.1-1
    Update to KDE 4.1.1

Modified:
  kdelibs/trunk/PKGBUILD
Deleted:
  kdelibs/trunk/refcount.patch

----------------+
 PKGBUILD       |   20 ++++--------
 refcount.patch |   90 -------------------------------------------------------
 2 files changed, 8 insertions(+), 102 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2008-08-29 07:03:08 UTC (rev 10430)
+++ PKGBUILD	2008-08-29 07:06:14 UTC (rev 10431)
@@ -1,9 +1,9 @@
-# $ Id: $
+# $Id$
 # Maintainer: Pierre Schmitz <pierre at archlinux.de>
 
 pkgname=kdelibs
-pkgver=4.1.0
-pkgrel=4
+pkgver=4.1.1
+pkgrel=1
 pkgdesc="KDE Core Libraries"
 arch=('i686' 'x86_64')
 url='http://www.kde.org'
@@ -11,23 +11,19 @@
 groups=('kde')
 depends=('libxcursor' 'phonon' 'shared-mime-info' 'qt>=4.4' 'libxpm'
 	 'enchant' 'jasper' 'openexr' 'strigi' 'bzip2' 'libxslt' 'libxtst'
-	 'giflib' 'soprano' 'ca-certificates' 'heimdal')
+	 'giflib' 'soprano' 'ca-certificates' 'heimdal' 'pmount')
 makedepends=('pkgconfig' 'cmake' 'automoc4' 'intltool' 'avahi' 'libgl')
 replaces=('arts')
 options=('docs')
-source=("ftp://ftp.archlinux.org/other/kde/${pkgname}-${pkgver}.tar.bz2"
-        'kde-applications-menu.patch'
-        'refcount.patch')
-md5sums=('a72fd8653b86f73860d0e7ebf0f2d606'
-         '3daa0f01fe26325fb3dbd807a04898ad'
-         '754015620274dfce933d8691f8686f84')
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.bz2"
+        'kde-applications-menu.patch')
+md5sums=('fe3457ff49ed44a2084442a5950417be'
+         '3daa0f01fe26325fb3dbd807a04898ad')
 
 build() {
 	cd $srcdir/${pkgname}-${pkgver}
 	# avoid file conflict with gnome-menu
 	patch -p1 -i $srcdir/kde-applications-menu.patch || return 1
-	# fix closing of apps; see http://bugs.kde.org/show_bug.cgi?id=167826
-	patch -p1 -i $srcdir/refcount.patch || return 1
 	cd ..
 	mkdir build
 	cd build

Deleted: refcount.patch
===================================================================
--- refcount.patch	2008-08-29 07:03:08 UTC (rev 10430)
+++ refcount.patch	2008-08-29 07:06:14 UTC (rev 10431)
@@ -1,90 +0,0 @@
-Index: kdelibs/kdeui/widgets/kmainwindow.cpp
-===================================================================
---- kdelibs/kdeui/widgets/kmainwindow.cpp	(Revision 840376)
-+++ kdelibs/kdeui/widgets/kmainwindow.cpp	(Revision 840379)
-@@ -226,6 +226,11 @@
- {
-     KGlobal::ref();
- 
-+    // We set allow quit to true, so when the refcounting reaches 0 the application instance will
-+    // be exited. This has a similar purpose than setQuitOnLastWindowClosed (from
-+    // QApplication), but it honors (de)refing from KGlobal.
-+    KGlobal::setAllowQuit(true);
-+
-     q = _q;
- 
-     q->setAnimated(KGlobalSettings::graphicEffectsLevel() & KGlobalSettings::SimpleAnimationEffects);
-Index: kdelibs/kdecore/kernel/kglobal.cpp
-===================================================================
---- kdelibs/kdecore/kernel/kglobal.cpp	(Revision 840376)
-+++ kdelibs/kdecore/kernel/kglobal.cpp	(Revision 840379)
-@@ -251,11 +251,14 @@
- 
- /**
-  * This counter indicates when to quit the application.
-- * It starts at 1, is decremented in KMainWindow when the last window is closed, but
-- * is incremented by operations that should outlive the last window closed
-- * (e.g. a file copy for a file manager, or 'compacting folders on exit' for a mail client).
-+ * It starts at 0, is incremented by KMainWindow, systray icons, running jobs, etc.
-+ * and decremented again when those things are destroyed.
-+ * This mechanism allows dialogs and jobs to outlive the last window closed
-+ * e.g. a file copy for a file manager, or 'compacting folders on exit' for a mail client,
-+ * the job progress widget with "keep open" checked, etc.
-  */
--static int s_refCount = 1;
-+static int s_refCount = 0;
-+static bool s_allowQuit = false;
- 
- void KGlobal::ref()
- {
-@@ -267,9 +270,14 @@
- {
-     --s_refCount;
-     //kDebug() << "KGlobal::deref() : refCount = " << s_refCount;
--    if (s_refCount <= 0) {
-+    if (s_refCount <= 0 && s_allowQuit) {
-         QCoreApplication::instance()->quit();
-     }
- }
- 
-+void KGlobal::setAllowQuit(bool allowQuit)
-+{
-+    s_allowQuit = allowQuit;
-+}
-+
- #undef PRIVATE_DATA
-Index: kdelibs/kdecore/kernel/kglobal.h
-===================================================================
---- kdelibs/kdecore/kernel/kglobal.h	(Revision 840376)
-+++ kdelibs/kdecore/kernel/kglobal.h	(Revision 840379)
-@@ -409,6 +409,16 @@
-      * "last window closed" event, but some events should outlive the last window closed
-      * (e.g. a file copy for a file manager, or 'compacting folders on exit' for a mail client).
-      *
-+     * We have some use cases that we want to take care of (the format is "action refcount"):
-+     * - open window -> setAllowQuit(true) 1 ; close window 0 => EXIT
-+     * - job start 1; job end 0 [don't exit yet]; open window -> setAllowQuit(true) 1 ; close window 0 => EXIT
-+     * - job start 1; open window -> setAllowQuit(true) 2; close window 1; job end 0 => EXIT
-+     * - job start 1; open window -> setAllowQuit(true) 2; job end 1; close window 0 => EXIT
-+     * - open dialog 0; close dialog 0; => DO NOT EXIT
-+     * - job start 1; job end 0; create two main objects 2; delete both main objects 0 => EXIT
-+     * - open window -> setAllowQuit(true) 1; add systray icon 2; close window 1 => DO NOT EXIT
-+     * - open window -> setAllowQuit(true) 1; add systray icon 2; remove systray icon 1; close window 0 => EXIT
-+     *
-      * Note that for this to happen you must call qApp->setQuitOnLastWindowClosed(false),
-      * in main() for instance.
-      */
-@@ -421,6 +431,13 @@
-     KDECORE_EXPORT void deref();
- 
-     /**
-+     * If refcounting reaches 0 (or less), and @p allowQuit is true, the instance of the application
-+     * will automatically be exited. Otherwise, the application will not exit automatically.
-+     * @since 4.2
-+     */
-+    KDECORE_EXPORT void setAllowQuit(bool allowQuit);
-+
-+    /**
-      * The component currently active (useful in a multi-component
-      * application, such as a KParts application).
-      * Don't use this - it's mainly for KAboutDialog and KBugReport.




More information about the arch-commits mailing list