[Spice-commits] src/channel-webdav.c src/giopipe.c src/spice-widget.c src/spice-widget-egl.c
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Jul 25 10:54:30 UTC 2018
src/channel-webdav.c | 6 ------
src/giopipe.c | 2 --
src/spice-widget-egl.c | 3 ---
src/spice-widget.c | 15 ---------------
4 files changed, 26 deletions(-)
New commits:
commit bd78558b4e658fe761b746f5bc91c5193e822dca
Author: Frediano Ziglio <fziglio at redhat.com>
Date: Fri Jul 20 18:09:54 2018 +0100
Remove deprecation blocks not needed anymore
Some deprecation blocks in the code were there to avoid
warning when using too recent GTK and Glib functions.
Now that we bump GTK version remove these warning avoidance.
Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
Acked-by: Victor Toso <victortoso at redhat.com>
diff --git a/src/channel-webdav.c b/src/channel-webdav.c
index 79e3f33..8e4db1a 100644
--- a/src/channel-webdav.c
+++ b/src/channel-webdav.c
@@ -314,9 +314,7 @@ static void demux_to_client_cb(GObject *source, GAsyncResult *result, gpointer u
gboolean fail;
gsize size;
-G_GNUC_BEGIN_IGNORE_DEPRECATIONS
g_output_stream_write_all_finish(G_OUTPUT_STREAM(source), result, &size, &error);
-G_GNUC_END_IGNORE_DEPRECATIONS
if (error) {
CHANNEL_DEBUG(client->self, "write failed: %s", error->message);
@@ -338,11 +336,9 @@ static void demux_to_client(Client *client)
CHANNEL_DEBUG(client->self, "pushing %"G_GSIZE_FORMAT" to client %p", size, client);
if (size > 0) {
-G_GNUC_BEGIN_IGNORE_DEPRECATIONS
g_output_stream_write_all_async(g_io_stream_get_output_stream(client->pipe),
c->demux.buf, size, G_PRIORITY_DEFAULT,
c->cancellable, demux_to_client_cb, client);
-G_GNUC_END_IGNORE_DEPRECATIONS
return;
} else {
/* Nothing to write */
@@ -377,9 +373,7 @@ static void start_client(SpiceWebdavChannel *self)
client->cancellable = g_cancellable_new();
spice_make_pipe(&client->pipe, &peer);
-G_GNUC_BEGIN_IGNORE_DEPRECATIONS
addr = g_inet_socket_address_new_from_string ("127.0.0.1", 0);
-G_GNUC_END_IGNORE_DEPRECATIONS
if (!soup_server_accept_iostream(server, peer, addr, addr, &error))
goto fail;
diff --git a/src/giopipe.c b/src/giopipe.c
index c653cb8..de1adae 100644
--- a/src/giopipe.c
+++ b/src/giopipe.c
@@ -482,10 +482,8 @@ spice_make_pipe(GIOStream **p1, GIOStream **p2)
make_gio_pipe(&in1, &out2);
make_gio_pipe(&in2, &out1);
-G_GNUC_BEGIN_IGNORE_DEPRECATIONS
*p1 = g_simple_io_stream_new(in1, out1);
*p2 = g_simple_io_stream_new(in2, out2);
-G_GNUC_END_IGNORE_DEPRECATIONS
g_object_unref(in1);
g_object_unref(in2);
diff --git a/src/spice-widget-egl.c b/src/spice-widget-egl.c
index a6805dd..011d8c7 100644
--- a/src/spice-widget-egl.c
+++ b/src/spice-widget-egl.c
@@ -312,12 +312,9 @@ gl_make_current(SpiceDisplay *display, GError **err)
else
#endif
{
- /* Ignore GLib's too-new warnings */
- G_GNUC_BEGIN_IGNORE_DEPRECATIONS
GtkWidget *area = gtk_stack_get_child_by_name(d->stack, "gl-area");
gtk_gl_area_make_current(GTK_GL_AREA(area));
- G_GNUC_END_IGNORE_DEPRECATIONS
}
return TRUE;
diff --git a/src/spice-widget.c b/src/spice-widget.c
index ec8b61b..24c42a8 100644
--- a/src/spice-widget.c
+++ b/src/spice-widget.c
@@ -574,8 +574,6 @@ static void grab_notify(SpiceDisplay *display, gboolean was_grabbed)
}
#if HAVE_EGL
-/* Ignore GLib's too-new warnings */
-G_GNUC_BEGIN_IGNORE_DEPRECATIONS
static gboolean
gl_area_render(GtkGLArea *area, GdkGLContext *context, gpointer user_data)
{
@@ -607,7 +605,6 @@ gl_area_realize(GtkGLArea *area, gpointer user_data)
g_clear_error(&err);
}
}
-G_GNUC_END_IGNORE_DEPRECATIONS
#endif
static void
@@ -644,8 +641,6 @@ static void spice_display_init(SpiceDisplay *display)
gtk_stack_set_visible_child(d->stack, area);
#if HAVE_EGL
-/* Ignore GLib's too-new warnings */
-G_GNUC_BEGIN_IGNORE_DEPRECATIONS
area = gtk_gl_area_new();
gtk_gl_area_set_required_version(GTK_GL_AREA(area), 3, 2);
gtk_gl_area_set_auto_render(GTK_GL_AREA(area), false);
@@ -654,7 +649,6 @@ G_GNUC_BEGIN_IGNORE_DEPRECATIONS
"signal::realize", gl_area_realize, display,
NULL);
gtk_stack_add_named(d->stack, area, "gl-area");
-G_GNUC_END_IGNORE_DEPRECATIONS
#endif
area = gtk_drawing_area_new();
gtk_stack_add_named(d->stack, area, "gst-area");
@@ -813,9 +807,7 @@ static GdkSeat *spice_display_get_default_seat(SpiceDisplay *display)
{
GdkWindow *window = gtk_widget_get_window(GTK_WIDGET(display));
GdkDisplay *gdk_display = gdk_window_get_display(window);
- G_GNUC_BEGIN_IGNORE_DEPRECATIONS
return gdk_display_get_default_seat(gdk_display);
- G_GNUC_END_IGNORE_DEPRECATIONS
}
/* FIXME: gdk_keyboard_grab/ungrab() is deprecated */
@@ -1028,7 +1020,6 @@ static gboolean do_pointer_grab(SpiceDisplay *display)
#endif
try_keyboard_grab(display);
- G_GNUC_BEGIN_IGNORE_DEPRECATIONS
status = gdk_seat_grab(spice_display_get_default_seat(display),
window,
GDK_SEAT_CAPABILITY_ALL_POINTING,
@@ -1037,7 +1028,6 @@ static gboolean do_pointer_grab(SpiceDisplay *display)
NULL,
NULL,
NULL);
- G_GNUC_END_IGNORE_DEPRECATIONS
grab_successful = (status == GDK_GRAB_SUCCESS);
if (!grab_successful) {
d->mouse_grab_active = false;
@@ -2400,9 +2390,7 @@ static void spice_display_class_init(SpiceDisplayClass *klass)
static GdkDevice *spice_gdk_window_get_pointing_device(GdkWindow *window)
{
GdkDisplay *gdk_display = gdk_window_get_display(window);
- G_GNUC_BEGIN_IGNORE_DEPRECATIONS
return gdk_seat_get_pointer(gdk_display_get_default_seat(gdk_display));
- G_GNUC_END_IGNORE_DEPRECATIONS
}
static GdkModifierType spice_display_get_modifiers_state(SpiceDisplay *display)
@@ -2909,10 +2897,7 @@ static void gl_draw(SpiceDisplay *display,
gl = gtk_stack_get_child_by_name(d->stack, "gl-area");
if (gtk_stack_get_visible_child(d->stack) == gl) {
- /* Ignore GLib's too-new warnings */
- G_GNUC_BEGIN_IGNORE_DEPRECATIONS
gtk_gl_area_queue_render(GTK_GL_AREA(gl));
- G_GNUC_END_IGNORE_DEPRECATIONS
d->egl.call_draw_done = TRUE;
} else {
spice_egl_update_display(display);
More information about the Spice-commits
mailing list