[PATCH spice-gtk 3/4] fixup! build-sys: bump gtk requirement 3.12 -> 3.22

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Add needed  G_GNUC_BEGIN_IGNORE_DEPRECATIONS/G_GNUC_END_IGNORE_DEPRECATIONS
for 3.22
---
 src/spice-gtk-session.c | 3 +++
 src/spice-widget.c      | 4 ++++
 2 files changed, 7 insertions(+)

diff --git a/src/spice-gtk-session.c b/src/spice-gtk-session.c
index 3d8973e1..6bca923b 100644
--- a/src/spice-gtk-session.c
+++ b/src/spice-gtk-session.c
@@ -178,7 +178,10 @@ static void guest_modifiers_changed(SpiceInputsChannel *inputs, gpointer data)
 static void spice_gtk_session_init(SpiceGtkSession *self)
 {
     SpiceGtkSessionPrivate *s;
+/* Ignore GLib's too-new warnings */
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
     GdkKeymap *keymap = gdk_keymap_get_default();
+G_GNUC_END_IGNORE_DEPRECATIONS
 
     s = self->priv = spice_gtk_session_get_instance_private(self);
 
diff --git a/src/spice-widget.c b/src/spice-widget.c
index 509cf99d..3a330ada 100644
--- a/src/spice-widget.c
+++ b/src/spice-widget.c
@@ -1109,8 +1109,10 @@ static void mouse_wrap(SpiceDisplay *display, GdkEventMotion *motion)
     d->mouse_last_y = -1;
 #else
     GdkScreen *screen = gtk_widget_get_screen(GTK_WIDGET(display));
+    G_GNUC_BEGIN_IGNORE_DEPRECATIONS
     xr = gdk_screen_get_width(screen) / 2;
     yr = gdk_screen_get_height(screen) / 2;
+    G_GNUC_END_IGNORE_DEPRECATIONS
 
     if (xr != (gint)motion->x_root || yr != (gint)motion->y_root) {
         GdkWindow *window = gtk_widget_get_window(GTK_WIDGET(display));
@@ -1688,6 +1690,7 @@ static guint get_scancode_from_keyval(SpiceDisplay *display, guint keyval)
     GdkKeymapKey *keys = NULL;
     gint n_keys = 0;
 
+    G_GNUC_BEGIN_IGNORE_DEPRECATIONS
     if (gdk_keymap_get_entries_for_keyval(gdk_keymap_get_default(),
                                           keyval, &keys, &n_keys)) {
         /* FIXME what about levels? */
@@ -1697,6 +1700,7 @@ static guint get_scancode_from_keyval(SpiceDisplay *display, guint keyval)
         g_warning("could not lookup keyval %u, please report a bug", keyval);
         return 0;
     }
+    G_GNUC_END_IGNORE_DEPRECATIONS
 
     return vnc_display_keymap_gdk2xtkbd(d->keycode_map, d->keycode_maplen, keycode);
 }
-- 
2.17.1

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux Virtualization]     [Linux Virtualization]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]