1
0
Fork 0
mirror of https://gitlab.gnome.org/GNOME/calls.git synced 2024-11-10 10:31:20 +00:00

record-row: Use API to query call icon name

This makes sure we don't need to allocate icon string names for each record.
This commit is contained in:
Evangelos Ribeiro Tzaras 2021-12-07 11:03:56 +01:00
parent a87c3eeb2e
commit 42b5b9d600

View file

@ -227,9 +227,6 @@ update_time (CallsCallRecordRow *self,
GDateTime *answered,
GDateTime *end)
{
gboolean missed = FALSE;
gchar *type_icon_name;
if (end) {
gboolean time_final;
@ -237,19 +234,11 @@ update_time (CallsCallRecordRow *self,
if (!time_final && !self->date_change_timeout)
setup_date_change_timeout (self);
if (!answered)
missed = TRUE;
}
type_icon_name = g_strdup_printf
("call-arrow-%s%s-symbolic",
inbound ? "incoming" : "outgoing",
missed ? "-missed" : "");
gtk_image_set_from_icon_name (self->type, type_icon_name,
gtk_image_set_from_icon_name (self->type,
get_call_icon_symbolic_name (inbound, !answered),
GTK_ICON_SIZE_MENU);
g_free (type_icon_name);
}