[kdebase-runtime] fix knotify, workaround Qt 4.8 QUrl.toLocalFile behavior change (#749213)

Rex Dieter rdieter at fedoraproject.org
Wed Oct 26 19:28:57 UTC 2011


commit edacdffa8b0e0a2ffbc360b9c2f0be381f6be339
Author: Rex Dieter <rdieter at fedoraproject.org>
Date:   Wed Oct 26 14:36:21 2011 -0500

    fix knotify, workaround Qt 4.8 QUrl.toLocalFile behavior change (#749213)

 kde-runtime-4.7.2-knotify_qt48_qurl.patch |   17 +++++++++++++++++
 kdebase-runtime.spec                      |   11 ++++++++++-
 2 files changed, 27 insertions(+), 1 deletions(-)
---
diff --git a/kde-runtime-4.7.2-knotify_qt48_qurl.patch b/kde-runtime-4.7.2-knotify_qt48_qurl.patch
new file mode 100644
index 0000000..69c5fbb
--- /dev/null
+++ b/kde-runtime-4.7.2-knotify_qt48_qurl.patch
@@ -0,0 +1,17 @@
+diff -up kde-runtime-4.7.2/knotify/notifybysound.cpp.qt48 kde-runtime-4.7.2/knotify/notifybysound.cpp
+--- kde-runtime-4.7.2/knotify/notifybysound.cpp.qt48	2011-05-20 15:32:25.000000000 -0500
++++ kde-runtime-4.7.2/knotify/notifybysound.cpp	2011-10-26 14:30:49.409834322 -0500
+@@ -212,6 +212,13 @@ void NotifyBySound::notify( int eventId,
+ 	KUrl soundFileURL = config->readEntry( "Sound" , true );
+ 	QString soundFile = soundFileURL.toLocalFile();
+ 
++	// hack around http://bugs.kde.org/285028
++	if (soundFile.isEmpty()) 
++	{
++		soundFileURL.setUrl("file:" + soundFileURL.url());
++		soundFile = soundFileURL.toLocalFile();
++	}
++
+ 	if (soundFile.isEmpty())
+ 	{
+ 		finish( eventId );
diff --git a/kdebase-runtime.spec b/kdebase-runtime.spec
index 78f1f41..b128c25 100644
--- a/kdebase-runtime.spec
+++ b/kdebase-runtime.spec
@@ -14,7 +14,7 @@
 Name:          kdebase-runtime
 Summary:       KDE Runtime
 Version:       4.7.2
-Release:       5%{?dist}
+Release:       6%{?dist}
 
 # http://techbase.kde.org/Policies/Licensing_Policy
 License:       LGPLv2+
@@ -45,6 +45,11 @@ Patch9:        kdebase-runtime-4.3.4-man-overrides.patch
 # To build/include activitymanager or not
 Patch10: kde-runtime-4.7.2-no_activitymanager.patch
 
+## upstreamable patches
+# workaround Qt 4.8 QUrl.toLocalFile behavior change
+# http://bugzilla.redhat.com/749213
+Patch50: kde-runtime-4.7.2-knotify_qt48_qurl.patch 
+
 ## upstream patches
 
 Obsoletes: kdebase4-runtime < %{version}-%{release}
@@ -151,6 +156,7 @@ BuildArch: noarch
 %if 0%{?no_activitymanager}
 %patch10 -p1 -b .no_activitymanager
 %endif
+%patch50 -p1 -b .knotify_qt48_qurl
 
 
 %build
@@ -305,6 +311,9 @@ fi
 
 
 %changelog
+* Wed Oct 26 2011 Rex Dieter <rdieter at fedoraproject.org> 4.7.2-6
+- fix knotify, workaround Qt 4.8 QUrl.toLocalFile behavior change (#749213)
+
 * Tue Oct 25 2011 Rex Dieter <rdieter at fedoraproject.org> 4.7.2-5
 - include toggle to omit activitymanager
 


More information about the scm-commits mailing list