aboutsummaryrefslogtreecommitdiff
path: root/debian/patches/replace-deprecated-gtk.patch
diff options
context:
space:
mode:
Diffstat (limited to 'debian/patches/replace-deprecated-gtk.patch')
-rw-r--r--debian/patches/replace-deprecated-gtk.patch63
1 files changed, 63 insertions, 0 deletions
diff --git a/debian/patches/replace-deprecated-gtk.patch b/debian/patches/replace-deprecated-gtk.patch
new file mode 100644
index 0000000..e4a2f15
--- /dev/null
+++ b/debian/patches/replace-deprecated-gtk.patch
@@ -0,0 +1,63 @@
+Description: Remove deprecated GTK functions
+ Remove gtk_set_locale() and change gdk_window_lookup() to gdk_x11_window_lookup_for_display().
+ Fixes "pointer-trouble-at-implicit" and "pointer-from-integer" warnings.
+Author: Dmitry Borisyuk <q1werty@i.com.ua>
+--- a/eggtrayicon.c
++++ b/eggtrayicon.c
+@@ -111,7 +111,7 @@
+ gdkwin = gdk_window_lookup_for_display (gtk_widget_get_display (widget),
+ icon->manager_window);
+ #else
+- gdkwin = gdk_window_lookup (icon->manager_window);
++ gdkwin = gdk_x11_window_lookup_for_display (gdk_display_get_default(), icon->manager_window);
+ #endif
+
+ gdk_window_remove_filter (gdkwin, egg_tray_icon_manager_filter, icon);
+@@ -120,7 +120,7 @@
+ #if HAVE_GTK_MULTIHEAD
+ root_window = gdk_screen_get_root_window (gtk_widget_get_screen (widget));
+ #else
+- root_window = gdk_window_lookup (gdk_x11_get_default_root_xwindow ());
++ root_window = gdk_x11_window_lookup_for_display (gdk_display_get_default(), gdk_x11_get_default_root_xwindow ());
+ #endif
+
+ gdk_window_remove_filter (root_window, egg_tray_icon_manager_filter, icon);
+@@ -192,7 +192,7 @@
+ gdkwin = gdk_window_lookup_for_display (gtk_widget_get_display (GTK_WIDGET (icon)),
+ icon->manager_window);
+ #else
+- gdkwin = gdk_window_lookup (icon->manager_window);
++ gdkwin = gdk_x11_window_lookup_for_display (gdk_display_get_default(), icon->manager_window);
+ #endif
+
+ gdk_window_remove_filter (gdkwin, egg_tray_icon_manager_filter, icon);
+@@ -218,7 +218,7 @@
+ gdkwin = gdk_window_lookup_for_display (gtk_widget_get_display (GTK_WIDGET (icon)),
+ icon->manager_window);
+ #else
+- gdkwin = gdk_window_lookup (icon->manager_window);
++ gdkwin = gdk_x11_window_lookup_for_display (gdk_display_get_default(), icon->manager_window);
+ #endif
+
+ gdk_window_add_filter (gdkwin, egg_tray_icon_manager_filter, icon);
+@@ -274,7 +274,7 @@
+ #if HAVE_GTK_MULTIHEAD
+ root_window = gdk_screen_get_root_window (gtk_widget_get_screen (screen));
+ #else
+- root_window = gdk_window_lookup (gdk_x11_get_default_root_xwindow ());
++ root_window = gdk_x11_window_lookup_for_display (gdk_display_get_default(), gdk_x11_get_default_root_xwindow ());
+ #endif
+
+ /* Add a root window filter so that we get changes on MANAGER */
+--- a/fbxkb.c
++++ b/fbxkb.c
+@@ -510,8 +510,7 @@
+ main(int argc, char *argv[], char *env[])
+ {
+ ENTER;
+- setlocale(LC_CTYPE, "");
+- gtk_set_locale();
++ setlocale(LC_ALL, "");
+ gtk_init(&argc, &argv);
+ XSetLocaleModifiers("");
+ XSetErrorHandler((XErrorHandler) Xerror_handler);
bgstack15