diff options
author | Matt Porter <mporter@konsulko.com> | 2017-05-21 08:16:20 -0400 |
---|---|---|
committer | Matt Porter <mporter@konsulko.com> | 2017-05-21 08:19:31 -0400 |
commit | 07502ed69e6d6a1830c168aada4c59ab0220bd24 (patch) | |
tree | 7b525ddd1170863e3f99c2f314feb1e117ab28b3 /telephony-binding | |
parent | 1f5cd7758161271e7e7c38e5a7dc78396f5c56b8 (diff) |
Add incoming call rejection to telephony binding and phone UI
Adds support for disconnection of an alerting incoming call to
the telephony binding via the hangup verb. This is support in
the phone UI by an additional button being loaded in the
incoming call state allowing the user to decline to answer the
call or use the already present answer call button to accept
it.
AGL-Bug: SPEC-601
Change-Id: I56ad0b813c0f1f24688709d180c3c061d7511651
Signed-off-by: Matt Porter <mporter@konsulko.com>
Diffstat (limited to 'telephony-binding')
-rw-r--r-- | telephony-binding/telephony-binding.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/telephony-binding/telephony-binding.c b/telephony-binding/telephony-binding.c index 41164f0..e3c6d2f 100644 --- a/telephony-binding/telephony-binding.c +++ b/telephony-binding/telephony-binding.c @@ -64,6 +64,10 @@ static void hangup(struct afb_req request) DEBUG(interface, "Hangup voice call\n"); ofono_voicecall_hangup(voice_call); afb_req_success(request, NULL, NULL); + } else if (incoming_call) { + DEBUG(interface, "Reject incoming call\n"); + ofono_voicecall_hangup(incoming_call); + afb_req_success(request, NULL, NULL); } else { ERROR(interface, "Hangup: no active call"); afb_req_fail(request, "failed hangup", NULL); |