From a228a2715e2ee99dd0a315e64c9bddfd3dcdb0df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Grisez?= Date: Mon, 20 Jul 2015 14:25:59 +0200 Subject: [PATCH] Disables changing cursor when it hovers a chatroom link with GTK+ version < 2.22 This feature cannot be implemented because gdk_cursor_get_cursor_type() is unavailable --- gtk/chat.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gtk/chat.c b/gtk/chat.c index 837dc8926..be66dabb0 100644 --- a/gtk/chat.c +++ b/gtk/chat.c @@ -437,6 +437,7 @@ static gboolean link_event_handler(GtkTextTag *tag, GObject *text_view,GdkEvent } static void chatroom_enable_hand_cursor(GdkWindow *window, gboolean hand_cursor_enabled) { +#if GTK_CHECK_VERSION(2,22,0) GdkCursor *cursor = gdk_window_get_cursor(window); GdkCursor *new_cursor = NULL; if(!hand_cursor_enabled && gdk_cursor_get_cursor_type(cursor) != GDK_XTERM) { @@ -448,6 +449,7 @@ static void chatroom_enable_hand_cursor(GdkWindow *window, gboolean hand_cursor_ gdk_window_set_cursor(window, new_cursor); gdk_cursor_unref(new_cursor); } +#endif } static gboolean chatroom_event(GtkWidget *widget, GdkEvent *event, gpointer user_data) {