summaryrefslogtreecommitdiffstats
path: root/mozilla-notify.patch
diff options
context:
space:
mode:
Diffstat (limited to 'mozilla-notify.patch')
-rw-r--r--mozilla-notify.patch37
1 files changed, 32 insertions, 5 deletions
diff --git a/mozilla-notify.patch b/mozilla-notify.patch
index 54a1c59..7c865de 100644
--- a/mozilla-notify.patch
+++ b/mozilla-notify.patch
@@ -1,12 +1,39 @@
-diff -up xulrunner-2.0/mozilla-central/toolkit/system/gnome/nsAlertsIconListener.cpp.notify xulrunner-2.0/mozilla-central/toolkit/system/gnome/nsAlertsIconListener.cpp
---- xulrunner-2.0/mozilla-central/toolkit/system/gnome/nsAlertsIconListener.cpp.notify 2010-11-02 17:02:18.266180000 -0400
-+++ xulrunner-2.0/mozilla-central/toolkit/system/gnome/nsAlertsIconListener.cpp 2010-11-02 17:02:37.699180028 -0400
-@@ -218,7 +218,7 @@ nsAlertsIconListener::ShowAlert(GdkPixbu
+https://bugzilla.mozilla.org/show_bug.cgi?id=628222
+
+# HG changeset patch
+# User Priit Laes <plaes@plaes.org>
+# Date 1295907218 -7200
+# Node ID ebfe5822e8916cce3d1811e67f6cb95ba3caeb24
+# Parent e874889e43d1b40f16c8234d53f39126a04e6621
+Add support for libnotify-0.7+
+
+diff -r e874889e43d1 -r ebfe5822e891 toolkit/system/gnome/nsAlertsIconListener.cpp
+--- a/toolkit/system/gnome/nsAlertsIconListener.cpp Fri Jan 21 16:45:23 2011 -0500
++++ b/toolkit/system/gnome/nsAlertsIconListener.cpp Tue Jan 25 00:13:38 2011 +0200
+@@ -46,6 +46,11 @@
+
+ #include <gdk/gdk.h>
+
++// Compatibility macro for <libnotify-0.7
++#ifndef NOTIFY_CHECK_VERSION
++#define NOTIFY_CHECK_VERSION(x,y,z) 0
++#endif
++
+ static PRBool gHasActions = PR_FALSE;
+
+ static void notify_action_cb(NotifyNotification *notification,
+@@ -218,7 +223,13 @@
{
mNotification = notify_notification_new(mAlertTitle.get(),
mAlertText.get(),
- NULL, NULL);
-+ NULL);
++ NULL
++// >=libnotify-0.7.0 has no support for attaching to widgets
++#if !NOTIFY_CHECK_VERSION(0,7,0)
++ , NULL
++#endif
++ );
++
if (!mNotification)
return NS_ERROR_OUT_OF_MEMORY;