From 1c9be03bce0df01013d0d252e6e1711798d9c090 Mon Sep 17 00:00:00 2001 From: Xavier Claessens Date: Fri, 30 Jan 2009 17:08:35 +0000 Subject: Prefix "Empathy" to the notification enum. svn path=/trunk/; revision=2304 --- src/empathy-chat-window.c | 4 ++-- src/empathy-misc.h | 12 ++++++------ src/empathy-status-icon.c | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) (limited to 'src') diff --git a/src/empathy-chat-window.c b/src/empathy-chat-window.c index 83f9c8166..d7c1a398f 100644 --- a/src/empathy-chat-window.c +++ b/src/empathy-chat-window.c @@ -845,13 +845,13 @@ static void chat_window_notification_closed_cb (NotifyNotification *notify, NotificationData *cb_data) { - int reason = 0; + EmpathyNotificationClosedReason reason = 0; EmpathyChatWindowPriv *priv = GET_PRIV (cb_data->window); #ifdef notify_notification_get_closed_reason reason = notify_notification_get_closed_reason (notify); #endif - if (reason == NOTIFICATION_CLOSED_DISMISSED) { + if (reason == EMPATHY_NOTIFICATION_CLOSED_DISMISSED) { empathy_chat_window_present_chat (cb_data->chat); } diff --git a/src/empathy-misc.h b/src/empathy-misc.h index 0d0613048..aaa743ca6 100644 --- a/src/empathy-misc.h +++ b/src/empathy-misc.h @@ -33,12 +33,12 @@ G_BEGIN_DECLS /* FIXME: this should *really* belong to libnotify. */ typedef enum { - NOTIFICATION_CLOSED_INVALID = 0, - NOTIFICATION_CLOSED_EXPIRED = 1, - NOTIFICATION_CLOSED_DISMISSED = 2, - NOTIFICATION_CLOSED_PROGRAMMATICALY = 3, - NOTIFICATION_CLOSED_RESERVED = 4 -} NotificationClosedReason; + EMPATHY_NOTIFICATION_CLOSED_INVALID = 0, + EMPATHY_NOTIFICATION_CLOSED_EXPIRED = 1, + EMPATHY_NOTIFICATION_CLOSED_DISMISSED = 2, + EMPATHY_NOTIFICATION_CLOSED_PROGRAMMATICALY = 3, + EMPATHY_NOTIFICATION_CLOSED_RESERVED = 4 +} EmpathyNotificationClosedReason; gboolean empathy_notification_is_enabled (void); GdkPixbuf * empathy_misc_get_pixbuf_for_notification (EmpathyContact *contact, diff --git a/src/empathy-status-icon.c b/src/empathy-status-icon.c index f6496003e..97eab7c29 100644 --- a/src/empathy-status-icon.c +++ b/src/empathy-status-icon.c @@ -84,7 +84,7 @@ status_icon_notification_closed_cb (NotifyNotification *notification, EmpathyStatusIcon *icon) { EmpathyStatusIconPriv *priv = GET_PRIV (icon); - int reason = 1; + EmpathyNotificationClosedReason reason = 0; #ifdef notify_notification_get_closed_reason reason = notify_notification_get_closed_reason (notification); @@ -101,7 +101,7 @@ status_icon_notification_closed_cb (NotifyNotification *notification, /* the notification has been closed by the user, see the * DesktopNotification spec. */ - if (reason == NOTIFICATION_CLOSED_DISMISSED) { + if (reason == EMPATHY_NOTIFICATION_CLOSED_DISMISSED) { /* use an idle here, as this callback is called from a * DBus signal handler inside libnotify, and we might call * a *_run_* method when activating the event. -- cgit v1.2.3