Gentoo Archives: gentoo-commits

From: "Samuli Suominen (ssuominen)" <ssuominen@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-voip/ekiga/files: ekiga-3.2.7-libnotify-0.7.patch
Date: Mon, 28 Feb 2011 17:15:48
Message-Id: 20110228171537.C77F220057@flycatcher.gentoo.org
1 ssuominen 11/02/28 17:15:37
2
3 Added: ekiga-3.2.7-libnotify-0.7.patch
4 Log:
5 Fix building with x11-libs/libnotify >= 0.7 wrt #355929 by "Kobboi".
6
7 (Portage version: 2.2.0_alpha25/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.1 net-voip/ekiga/files/ekiga-3.2.7-libnotify-0.7.patch
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-voip/ekiga/files/ekiga-3.2.7-libnotify-0.7.patch?rev=1.1&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-voip/ekiga/files/ekiga-3.2.7-libnotify-0.7.patch?rev=1.1&content-type=text/plain
14
15 Index: ekiga-3.2.7-libnotify-0.7.patch
16 ===================================================================
17 --- lib/engine/components/libnotify/libnotify-main.cpp
18 +++ lib/engine/components/libnotify/libnotify-main.cpp
19 @@ -40,6 +40,10 @@
20
21 #include <libnotify/notify.h>
22
23 +#ifndef NOTIFY_CHECK_VERSION
24 +#define NOTIFY_CHECK_VERSION(x,y,z) 0
25 +#endif
26 +
27 #include "services.h"
28 #include "notification-core.h"
29
30 @@ -158,7 +162,12 @@
31
32 notif = notify_notification_new (notification->get_title ().c_str (),
33 notification->get_body ().c_str (),
34 - urgency, NULL);
35 + urgency
36 +#if NOTIFY_CHECK_VERSION (0, 7, 0)
37 + );
38 +#else
39 + , NULL);
40 +#endif
41
42 g_signal_connect (notif, "closed",
43 G_CALLBACK (on_notif_closed), notification.get ());
44 --- src/gui/main.cpp
45 +++ src/gui/main.cpp
46 @@ -84,6 +84,9 @@
47
48 #ifdef HAVE_NOTIFY
49 #include <libnotify/notify.h>
50 +#ifndef NOTIFY_CHECK_VERSION
51 +#define NOTIFY_CHECK_VERSION(x,y,z) 0
52 +#endif
53 #endif
54
55 #if defined(P_FREEBSD) || defined (P_MACOSX)
56 @@ -2820,12 +2823,21 @@
57
58 body = g_strdup_printf ("%s\n%s\n%s", uri, app, account);
59
60 - notify = notify_notification_new (title, body, GM_ICON_LOGO, NULL);
61 + notify = notify_notification_new (title, body, GM_ICON_LOGO
62 +#if NOTIFY_CHECK_VERSION (0, 7, 0)
63 + );
64 +#else
65 + , NULL);
66 +#endif
67 notify_notification_add_action (notify, "accept", _("Accept"), notify_action_cb, mw, NULL);
68 notify_notification_add_action (notify, "reject", _("Reject"), notify_action_cb, mw, NULL);
69 notify_notification_set_timeout (notify, NOTIFY_EXPIRES_NEVER);
70 notify_notification_set_urgency (notify, NOTIFY_URGENCY_CRITICAL);
71 +#if NOTIFY_CHECK_VERSION (0, 7, 0)
72 + // notify_notification_attach_to_status_icon was removed
73 +#else
74 notify_notification_attach_to_status_icon (notify, statusicon);
75 +#endif
76 if (!notify_notification_show (notify, NULL)) {
77 ekiga_main_window_incoming_call_dialog_show (mw, call);
78 }