[packages/gtk+3] - added gtk+3-notify.patch, taken from git - rel 2

witekfl witekfl at pld-linux.org
Sat Jul 14 21:42:41 CEST 2012


commit 6198452dbde8b48f3df53b5691c54b6e1ce1a578
Author: witekfl <witekfl at poczta.onet.pl>
Date:   Sat Jul 14 21:37:09 2012 +0200

    - added gtk+3-notify.patch, taken from git
    - rel 2
    
    Without this patch python scripts using pynotify do not show notifications.
    Run /usr/lib/notification-daemon
    and sample python script:
    
    import pynotify
    pynotify.init("Test")
    n = pynotify.Notification("test", "test")
    n.show()

 gtk+3-notify.patch | 17 +++++++++++++++++
 gtk+3.spec         |  4 +++-
 2 files changed, 20 insertions(+), 1 deletion(-)
---
diff --git a/gtk+3-notify.patch b/gtk+3-notify.patch
new file mode 100644
index 0000000..be2a40a
--- /dev/null
+++ b/gtk+3-notify.patch
@@ -0,0 +1,17 @@
+diff --git a/gtk/gtkstatusicon.c b/gtk/gtkstatusicon.c
+index 8bcb638..efecdad 100644
+--- a/gtk/gtkstatusicon.c
++++ b/gtk/gtkstatusicon.c
+@@ -1328,10 +1328,9 @@ round_pixel_size (GtkWidget *widget,
+ 
+   for (s = GTK_ICON_SIZE_MENU; s <= GTK_ICON_SIZE_DIALOG; s++)
+     {
+-      if (gtk_icon_size_lookup_for_settings (settings, s, &w, &h) &&
+-	  w <= pixel_size && h <= pixel_size)
++	  if (gtk_icon_size_lookup_for_settings (settings, s, &w, &h))
+ 	{
+-	  d = MAX (pixel_size - w, pixel_size - h);
++	  d = MAX (abs (pixel_size - w), abs (pixel_size - h));
+ 	  if (d < dist)
+ 	    {
+ 	      dist = d;
diff --git a/gtk+3.spec b/gtk+3.spec
index def4762..f405f84 100644
--- a/gtk+3.spec
+++ b/gtk+3.spec
@@ -15,12 +15,13 @@ Summary(pl.UTF-8):	GIMP Toolkit
 Summary(tr.UTF-8):	GIMP ToolKit arayüz kitaplığı
 Name:		gtk+3
 Version:	3.4.3
-Release:	1
+Release:	2
 License:	LGPL v2+
 Group:		X11/Libraries
 Source0:	http://ftp.gnome.org/pub/GNOME/sources/gtk+/3.4/gtk+-%{version}.tar.xz
 # Source0-md5:	e552d52c3b0824eb99842dc9c5f4875f
 Patch0:		%{name}-papi.patch
+Patch1:		%{name}-notify.patch
 URL:		http://www.gtk.org/
 BuildRequires:	atk-devel >= 1:2.1.5
 BuildRequires:	autoconf >= 2.62
@@ -244,6 +245,7 @@ Moduł GTK+ do drukowania przez PAPI.
 %prep
 %setup -q -n gtk+-%{version}
 %patch0 -p1
+%patch1 -p1
 
 # for packaging clean examples
 # TODO: add am patch to do it like demos/gtk-demo via some configurable dir


More information about the pld-cvs-commit mailing list