mirror of
https://gitlab.gnome.org/GNOME/calls.git
synced 2024-11-10 10:31:20 +00:00
mm: origin: Try using own number as the origin name
This will make it easier to select an origin for outgoing calls. Without this change the name might be "0" which is not very expressive.
This commit is contained in:
parent
fecdc1fff8
commit
a888ac54b1
1 changed files with 8 additions and 1 deletions
|
@ -663,7 +663,14 @@ get_property (GObject *object,
|
|||
static gchar *
|
||||
modem_get_name (MMModem *modem)
|
||||
{
|
||||
gchar *name = NULL;
|
||||
char *name = NULL;
|
||||
const char * const *numbers = NULL;
|
||||
|
||||
numbers = mm_modem_get_own_numbers (modem);
|
||||
if (numbers && g_strv_length ((char **) numbers) > 0) {
|
||||
name = g_strdup (numbers[0]);
|
||||
return name;
|
||||
}
|
||||
|
||||
#define try(prop) \
|
||||
name = mm_modem_dup_##prop (modem); \
|
||||
|
|
Loading…
Reference in a new issue