summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharles Lehner <cel@celehner.com>2015-07-18 13:41:04 -0400
committerCharles Lehner <cel@celehner.com>2015-07-18 13:41:04 -0400
commit9649eeb782661a98b9a1e4d2aceadad19cfa5407 (patch)
tree84c79b19178b0faea604bfbc16c04d483b7e6f54
parent2076043d899a575c524a9c7132226d4461836aaf (diff)
gtk: support glib <2.4.2
-rw-r--r--modules/gtk/gtk_mod.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/gtk/gtk_mod.c b/modules/gtk/gtk_mod.c
index a6d804e..5ee451a 100644
--- a/modules/gtk/gtk_mod.c
+++ b/modules/gtk/gtk_mod.c
@@ -276,8 +276,14 @@ static void notify_incoming_call(struct gtk_mod *mod,
id[sizeof id - 1] = '\0';
notification = g_notification_new("Incoming call");
+
+#if GLIB_CHECK_VERSION(2,4,2)
g_notification_set_priority(notification,
G_NOTIFICATION_PRIORITY_URGENT);
+#else
+ g_notification_set_urgent(notification, TRUE);
+#endif
+
target = g_variant_new_int64(GPOINTER_TO_INT(call));
g_notification_set_body(notification, call_peeruri(call));
g_notification_add_button_with_target_value(notification,