aboutsummaryrefslogtreecommitdiff
path: root/src/im-application-list.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/im-application-list.c')
-rw-r--r--src/im-application-list.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/im-application-list.c b/src/im-application-list.c
index 1493adf..17fffdc 100644
--- a/src/im-application-list.c
+++ b/src/im-application-list.c
@@ -476,11 +476,12 @@ im_application_list_class_init (ImApplicationListClass *klass)
NULL, NULL,
g_cclosure_marshal_generic,
G_TYPE_NONE,
- 4,
+ 5,
G_TYPE_STRING,
G_TYPE_STRING,
G_TYPE_STRING,
- G_TYPE_STRING);
+ G_TYPE_STRING,
+ G_TYPE_BOOLEAN);
signals[SOURCE_REMOVED] = g_signal_new ("source-removed",
IM_TYPE_APPLICATION_LIST,
@@ -539,7 +540,7 @@ im_application_list_class_init (ImApplicationListClass *klass)
G_SIGNAL_RUN_FIRST,
0,
NULL, NULL,
- g_cclosure_marshal_VOID__OBJECT,
+ g_cclosure_marshal_VOID__STRING,
G_TYPE_NONE,
1,
G_TYPE_STRING);
@@ -806,6 +807,7 @@ im_application_list_source_changed (Application *app,
const gchar *string;
gboolean draws_attention;
gboolean old_draw;
+ gboolean visible;
g_variant_get (source, "(&s&s&sux&sb)",
&id, &label, &iconstr, &count, &time, &string, &draws_attention);
@@ -815,9 +817,11 @@ im_application_list_source_changed (Application *app,
g_action_group_change_action_state (G_ACTION_GROUP (app->source_actions), id,
g_variant_new ("(uxsb)", count, time, string, draws_attention));
- g_signal_emit (app->list, signals[SOURCE_CHANGED], 0, app->id, id, label, iconstr);
+ visible = count > 0;
+
+ g_signal_emit (app->list, signals[SOURCE_CHANGED], 0, app->id, id, label, iconstr, visible);
- if (!old_draw && draws_attention)
+ if (visible && !old_draw && draws_attention)
app->draws_attention = TRUE;
im_application_list_update_draws_attention (app->list);