aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-07-06 20:20:55 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-07-07 16:03:37 +0800
commitc4240a8b706c62564179654af0f6e423fa27b1e0 (patch)
tree838af37cae593cd601ea5854f612034f4a2d1221
parentcf452c7dd1d96a8d2f80b8cf8c64c03604a50c31 (diff)
downloadgsoc2013-empathy-c4240a8b706c62564179654af0f6e423fa27b1e0.tar
gsoc2013-empathy-c4240a8b706c62564179654af0f6e423fa27b1e0.tar.gz
gsoc2013-empathy-c4240a8b706c62564179654af0f6e423fa27b1e0.tar.bz2
gsoc2013-empathy-c4240a8b706c62564179654af0f6e423fa27b1e0.tar.lz
gsoc2013-empathy-c4240a8b706c62564179654af0f6e423fa27b1e0.tar.xz
gsoc2013-empathy-c4240a8b706c62564179654af0f6e423fa27b1e0.tar.zst
gsoc2013-empathy-c4240a8b706c62564179654af0f6e423fa27b1e0.zip
add answer/decline buttons in call notifications (#597124)
-rw-r--r--src/empathy-status-icon.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/empathy-status-icon.c b/src/empathy-status-icon.c
index 0f3fff1b7..08129b61d 100644
--- a/src/empathy-status-icon.c
+++ b/src/empathy-status-icon.c
@@ -119,6 +119,17 @@ notification_approve_cb (NotifyNotification *notification,
}
static void
+notification_decline_cb (NotifyNotification *notification,
+ gchar *action,
+ EmpathyStatusIcon *icon)
+{
+ EmpathyStatusIconPriv *priv = GET_PRIV (icon);
+
+ if (priv->event)
+ empathy_event_decline (priv->event);
+}
+
+static void
add_notification_actions (EmpathyStatusIcon *self,
NotifyNotification *notification)
{
@@ -131,6 +142,16 @@ add_notification_actions (EmpathyStatusIcon *self,
self, NULL);
break;
+ case EMPATHY_EVENT_TYPE_VOIP:
+ notify_notification_add_action (notification,
+ "reject", _("Reject"), (NotifyActionCallback) notification_decline_cb,
+ self, NULL);
+
+ notify_notification_add_action (notification,
+ "answer", _("Answer"), (NotifyActionCallback) notification_approve_cb,
+ self, NULL);
+ break;
+
default:
break;
}