]> git.0d.be Git - empathy.git/commitdiff
change empathy_notification_is_enabled to empathy_notify_manager_notification_is_enabled
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Thu, 12 Nov 2009 13:25:23 +0000 (13:25 +0000)
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Fri, 13 Nov 2009 11:37:18 +0000 (11:37 +0000)
Making it a method of EmpathyNotifyManager would allow us to cache the
gconf values if we want to.

libempathy-gtk/empathy-notify-manager.c
libempathy-gtk/empathy-notify-manager.h
src/empathy-chat-window.c
src/empathy-status-icon.c

index 7954dd9c7537332247a86b74b3f188245ca7d19a..ffcc34f486fbe9d22c814bc877701b89ebc5da96 100644 (file)
@@ -162,7 +162,7 @@ empathy_notify_manager_get_pixbuf_for_notification (EmpathyNotifyManager *self,
 }
 
 gboolean
-empathy_notification_is_enabled (void)
+empathy_notify_manager_notification_is_enabled  (EmpathyNotifyManager *self)
 {
   EmpathyConf *conf;
   gboolean res;
index 15740468e938891e66dac5a7af62017b73000558..4faa13b35af11749900d00cf8aa25c4e9daa329d 100644 (file)
@@ -82,7 +82,8 @@ EmpathyNotifyManager * empathy_notify_manager_dup_singleton (void);
 gboolean empathy_notify_manager_has_capability (EmpathyNotifyManager *self,
     const gchar *capa);
 
-gboolean empathy_notification_is_enabled  (void);
+gboolean empathy_notify_manager_notification_is_enabled  (
+    EmpathyNotifyManager *self);
 
 GdkPixbuf * empathy_notify_manager_get_pixbuf_for_notification (
     EmpathyNotifyManager *self,
index fc64d340f0c5ea2ce7188651ea21c5e063f842a5..4d99afd31b58d62b1ef5bce65ae746b9e686db2e 100644 (file)
@@ -1080,7 +1080,7 @@ chat_window_show_or_update_notification (EmpathyChatWindow *window,
        EmpathyChatWindowPriv *priv = GET_PRIV (window);
        gboolean res;
 
-       if (!empathy_notification_is_enabled ()) {
+       if (!empathy_notify_manager_notification_is_enabled (priv->notify_mgr)) {
                return;
        } else {
                empathy_conf_get_bool (empathy_conf_get (),
index 76c549ebbdfde82e00aa9b42efd50d4a1d1c0f64..1b0abdc39d155f892a51589a8c5b84c4f221bce8 100644 (file)
@@ -147,7 +147,7 @@ status_icon_update_notification (EmpathyStatusIcon *icon)
        EmpathyStatusIconPriv *priv = GET_PRIV (icon);
        GdkPixbuf *pixbuf = NULL;
 
-       if (!empathy_notification_is_enabled ()) {
+       if (!empathy_notify_manager_notification_is_enabled (priv->notify_mgr)) {
                /* always close the notification if this happens */
                notification_close_helper (priv);
                return;
@@ -331,7 +331,7 @@ status_icon_event_updated_cb (EmpathyEventManager *manager,
                return;
        }
 
-       if (empathy_notification_is_enabled ()) {
+       if (empathy_notify_manager_notification_is_enabled (priv->notify_mgr)) {
                status_icon_update_notification (icon);
        }
 
@@ -388,7 +388,7 @@ status_icon_idle_notify_cb (EmpathyStatusIcon *icon)
        status_icon_update_icon (icon);
        status_icon_update_tooltip (icon);
 
-       if (!empathy_notification_is_enabled ()) {
+       if (!empathy_notify_manager_notification_is_enabled (priv->notify_mgr)) {
                /* dismiss the outstanding notification if present */
 
                if (priv->notification) {