epiphany/epiphany-2.30.6-libnotify-0.7.patch

39 lines
1.0 KiB
Diff
Raw Permalink Normal View History

--- embed/downloader-view.c
+++ embed/downloader-view.c
@@ -36,6 +36,9 @@
#ifdef HAVE_LIBNOTIFY
#include <libnotify/notify.h>
+#ifndef NOTIFY_CHECK_VERSION
+#define NOTIFY_CHECK_VERSION(x,y,z) 0
+#endif
#endif
enum
@@ -337,7 +340,12 @@
g_object_ref (dv);
notification = notify_notification_new (title, msg,
- GTK_STOCK_INFO, NULL);
+ GTK_STOCK_INFO
+#if NOTIFY_CHECK_VERSION (0, 7, 0)
+ );
+#else
+ , NULL);
+#endif
g_signal_connect_after (notification, "closed",
G_CALLBACK (notification_closed_cb), dv);
@@ -346,7 +354,11 @@
notify_notification_set_timeout (notification, NOTIFY_EXPIRES_DEFAULT);
notify_notification_set_urgency (notification, NOTIFY_URGENCY_LOW);
+#if NOTIFY_CHECK_VERSION (0, 7, 0)
+ /* notify_notification_attach_to_status_icon was removed */
+#else
notify_notification_attach_to_status_icon (notification, status_icon);
+#endif
/* There are some visual glitches when the notification is shown and
* the GtkStatusIcon is still not visible. To avoid that, we delay the