diff options
Diffstat (limited to 'libempathy-gtk')
-rw-r--r-- | libempathy-gtk/empathy-ui-utils.c | 10 | ||||
-rw-r--r-- | libempathy-gtk/empathy-ui-utils.h | 2 |
2 files changed, 9 insertions, 3 deletions
diff --git a/libempathy-gtk/empathy-ui-utils.c b/libempathy-gtk/empathy-ui-utils.c index 7b55587ea..7c6166839 100644 --- a/libempathy-gtk/empathy-ui-utils.c +++ b/libempathy-gtk/empathy-ui-utils.c @@ -1647,7 +1647,7 @@ empathy_sound_play (GtkWidget *widget, } gboolean -empathy_notification_should_show (void) +empathy_notification_should_show (gboolean check_focus) { EmpathyConf *conf; gboolean res; @@ -1670,6 +1670,12 @@ empathy_notification_should_show (void) } } - return TRUE; + if (check_focus) { + empathy_conf_get_bool (conf, + EMPATHY_PREFS_NOTIFICATIONS_FOCUS, &res); + return res; + } else { + return TRUE; + } } diff --git a/libempathy-gtk/empathy-ui-utils.h b/libempathy-gtk/empathy-ui-utils.h index b3b26f0bb..455ddd7a2 100644 --- a/libempathy-gtk/empathy-ui-utils.h +++ b/libempathy-gtk/empathy-ui-utils.h @@ -132,7 +132,7 @@ void empathy_sound_play (GtkWidget *widge EmpathySound sound_id); /* Notifications */ -gboolean empathy_notification_should_show (void); +gboolean empathy_notification_should_show (gboolean check_focus); G_END_DECLS |