]> git.pld-linux.org Git - packages/gtk+3.git/commitdiff
upstream fix for "Can't set ParentRelative background for window"; rel 2 auto/th/gtk+3-3.24.2-2
authorJan Palus <atler@pld-linux.org>
Wed, 9 Jan 2019 22:30:06 +0000 (23:30 +0100)
committerJan Palus <atler@pld-linux.org>
Wed, 9 Jan 2019 22:30:06 +0000 (23:30 +0100)
see https://gitlab.gnome.org/GNOME/gtk/issues/1280

gtk+3.spec
parentrelative.patch [new file with mode: 0644]

index 12983907cb314a678d0abc6e5b2d941950da30d2..717f5bb1a4e9c0eac6fbc47c7f1e4b19cefda0f2 100644 (file)
@@ -21,7 +21,7 @@ Summary(pl.UTF-8):    GIMP Toolkit
 Summary(tr.UTF-8):     GIMP ToolKit arayüz kitaplığı
 Name:          gtk+3
 Version:       3.24.2
-Release:       1
+Release:       2
 License:       LGPL v2+
 Group:         X11/Libraries
 Source0:       http://ftp.gnome.org/pub/GNOME/sources/gtk+/3.24/gtk+-%{version}.tar.xz
@@ -30,6 +30,7 @@ Patch0:               %{name}-papi.patch
 Patch1:                typeahead.patch
 Patch2:                %{name}-cloudproviders.patch
 Patch3:                shooter.patch
+Patch4:                parentrelative.patch
 URL:           http://www.gtk.org/
 BuildRequires: at-spi2-atk-devel >= 2.6.0
 BuildRequires: atk-devel >= 1:2.16.0
@@ -292,6 +293,7 @@ Moduł GTK+ do drukowania przez PAPI.
 %endif
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1
 
 # for packaging clean examples
 # TODO: add am patch to do it like demos/gtk-demo via some configurable dir
diff --git a/parentrelative.patch b/parentrelative.patch
new file mode 100644 (file)
index 0000000..0549473
--- /dev/null
@@ -0,0 +1,41 @@
+From e3a1593a0984cc0156ec1892a46af8f256a64878 Mon Sep 17 00:00:00 2001
+From: Daniel Boles <dboles.src@gmail.com>
+Date: Thu, 13 Dec 2018 17:20:13 +0100
+Subject: [PATCH] x11: Fix deprecation macro use
+
+G_GNUC_END_IGNORE_DEPRECATIONS terminates the if statement and does not
+consider the following block to be part of the if. So that block was
+always taken irregardless of the pattern.
+
+Fixes #1280
+---
+ gdk/x11/gdkwindow-x11.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
+index 97ada6d739..764e39495f 100644
+--- a/gdk/x11/gdkwindow-x11.c
++++ b/gdk/x11/gdkwindow-x11.c
+@@ -2985,6 +2985,7 @@ gdk_window_x11_set_background (GdkWindow      *window,
+   double r, g, b, a;
+   cairo_surface_t *surface;
+   cairo_matrix_t matrix;
++  cairo_pattern_t *parent_relative_pattern;
+   if (GDK_WINDOW_DESTROYED (window))
+     return;
+@@ -2997,8 +2998,10 @@ gdk_window_x11_set_background (GdkWindow      *window,
+     }
+ G_GNUC_BEGIN_IGNORE_DEPRECATIONS
+-  if (pattern == gdk_x11_get_parent_relative_pattern ())
++  parent_relative_pattern = gdk_x11_get_parent_relative_pattern ();
+ G_GNUC_END_IGNORE_DEPRECATIONS
++
++  if (pattern == parent_relative_pattern)
+     {
+       GdkWindow *parent;
+-- 
+2.18.1
+
This page took 0.227034 seconds and 4 git commands to generate.