mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-30 09:49:26 +00:00
print status for incoming calls pending.
git-svn-id: svn+ssh://svn.savannah.nongnu.org/linphone/trunk@536 3f6dc0c8-ddfe-455d-9043-3cd528dc4637
This commit is contained in:
parent
c29c0d54f8
commit
430f84808d
3 changed files with 16 additions and 2 deletions
|
|
@ -333,6 +333,7 @@ lpc_cmd_help(LinphoneCore *lc, char *arg)
|
|||
}
|
||||
|
||||
static char callee_name[256]={0};
|
||||
static char caller_name[256]={0};
|
||||
|
||||
static int
|
||||
lpc_cmd_call(LinphoneCore *lc, char *args)
|
||||
|
|
@ -360,10 +361,18 @@ lpc_cmd_call(LinphoneCore *lc, char *args)
|
|||
return 1;
|
||||
}
|
||||
|
||||
static const char *linphonec_get_callee(){
|
||||
const char *linphonec_get_callee(){
|
||||
return callee_name;
|
||||
}
|
||||
|
||||
const char *linphonec_get_caller(){
|
||||
return caller_name;
|
||||
}
|
||||
|
||||
void linphonec_set_caller(const char *caller){
|
||||
snprintf(caller_name,sizeof(caller_name)-1,"%s",caller);
|
||||
}
|
||||
|
||||
static int
|
||||
lpc_cmd_refer(LinphoneCore *lc, char *args)
|
||||
{
|
||||
|
|
@ -1437,6 +1446,10 @@ static int lpc_cmd_status(LinphoneCore *lc, char *args)
|
|||
case GSTATE_CALL_IN_CONNECTED:
|
||||
linphonec_out("hook=answered duration=%i\n" ,
|
||||
linphone_core_get_current_call_duration(lc));
|
||||
break;
|
||||
case GSTATE_CALL_IN_INVITE:
|
||||
linphonec_out("Incoming call from %s\n",linphonec_get_caller());
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -216,6 +216,7 @@ linphonec_display_url (LinphoneCore * lc, const char *something, const char *url
|
|||
static void
|
||||
linphonec_call_received(LinphoneCore *lc, const char *from)
|
||||
{
|
||||
linphonec_set_caller(from);
|
||||
if ( auto_answer) {
|
||||
answer_call=TRUE;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ extern char *linphonec_readline(char *prompt);
|
|||
void linphonec_set_autoanswer(bool_t enabled);
|
||||
bool_t linphonec_get_autoanswer();
|
||||
void linphonec_command_finished(void);
|
||||
|
||||
void linphonec_set_caller(const char *caller);
|
||||
|
||||
#endif /* def LINPHONEC_H */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue