mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-19 12:08:11 +00:00
fix display name in call_log
This commit is contained in:
parent
7bf3cb7654
commit
a9dee01c72
2 changed files with 13 additions and 5 deletions
|
|
@ -210,13 +210,14 @@ void linphone_gtk_call_log_update(GtkWidget *w){
|
|||
for (logs=linphone_core_get_call_logs(linphone_gtk_get_core());logs!=NULL;logs=logs->next){
|
||||
LinphoneCallLog *cl=(LinphoneCallLog*)logs->data;
|
||||
GtkTreeIter iter, iter2;
|
||||
LinphoneAddress *la=linphone_call_log_get_dir(cl)==LinphoneCallIncoming ? linphone_call_log_get_from(cl) : linphone_call_log_get_to(cl);
|
||||
char *addr= linphone_address_as_string_uri_only (la);
|
||||
const LinphoneAddress *la=linphone_call_log_get_dir(cl)==LinphoneCallIncoming ? linphone_call_log_get_from(cl) : linphone_call_log_get_to(cl);
|
||||
char *addr= linphone_address_as_string(la);
|
||||
const char *display;
|
||||
gchar *logtxt, *headtxt, *minutes, *seconds;
|
||||
gchar quality[20];
|
||||
const char *status=NULL;
|
||||
gchar *start_date=NULL;
|
||||
LinphoneFriend *lf=NULL;
|
||||
int duration=linphone_call_log_get_duration(cl);
|
||||
time_t start_date_time=linphone_call_log_get_start_date(cl);
|
||||
|
||||
|
|
@ -229,12 +230,19 @@ void linphone_gtk_call_log_update(GtkWidget *w){
|
|||
#else
|
||||
start_date=g_strdup(ctime(&start_date_time));
|
||||
#endif
|
||||
lf=linphone_core_get_friend_by_address(linphone_gtk_get_core(),addr);
|
||||
if(lf != NULL){
|
||||
la=linphone_friend_get_address(lf);
|
||||
display=linphone_address_get_display_name(la);
|
||||
} else {
|
||||
display=linphone_address_get_display_name(la);
|
||||
}
|
||||
|
||||
display=linphone_address_get_display_name (la);
|
||||
if (display==NULL){
|
||||
display=linphone_address_get_username (la);
|
||||
if (display==NULL)
|
||||
if (display==NULL){
|
||||
display=linphone_address_get_domain (la);
|
||||
}
|
||||
}
|
||||
if (linphone_call_log_get_quality(cl)!=-1){
|
||||
snprintf(quality,sizeof(quality),"%.1f",linphone_call_log_get_quality(cl));
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ To add a translation file in linphone project you should first :
|
|||
- then add the file .po in the directory /po
|
||||
- run ./autogen.sh
|
||||
|
||||
Update the tranlation files
|
||||
Update the translation files
|
||||
***************************
|
||||
To update all the translation files, in the directory /po run the following command
|
||||
$ make update-po
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue