Merge branch 'mkirk/declined-call-notification'
This commit is contained in:
commit
bf59348972
@ -134,7 +134,7 @@ CHECKOUT OPTIONS:
|
||||
:commit: 521686c112bbae7a762f85d52b1e41eeb1760772
|
||||
:git: https://github.com/WhisperSystems/JSQMessagesViewController.git
|
||||
SignalServiceKit:
|
||||
:commit: 04ef06ce95d553116d6b53984f0dcf9429ab78f4
|
||||
:commit: 1fc5f7728613b7cc3f498d4e0fcccc5f8389b0a1
|
||||
:git: https://github.com/WhisperSystems/SignalServiceKit.git
|
||||
SocketRocket:
|
||||
:commit: 877ac7438be3ad0b45ef5ca3969574e4b97112bf
|
||||
|
||||
@ -733,7 +733,7 @@ protocol CallServiceObserver: class {
|
||||
}
|
||||
|
||||
/**
|
||||
* User chose to answer call referrred to by call `localId`. Used by the Callee only.
|
||||
* User chose to answer call referred to by call `localId`. Used by the Callee only.
|
||||
*
|
||||
* Used by notification actions which can't serialize a call object.
|
||||
*/
|
||||
@ -758,7 +758,7 @@ protocol CallServiceObserver: class {
|
||||
}
|
||||
|
||||
/**
|
||||
* User chose to answer call referrred to by call `localId`. Used by the Callee only.
|
||||
* User chose to answer call referred to by call `localId`. Used by the Callee only.
|
||||
*/
|
||||
public func handleAnswerCall(_ call: SignalCall) {
|
||||
AssertIsOnMainThread()
|
||||
@ -857,7 +857,14 @@ protocol CallServiceObserver: class {
|
||||
|
||||
Logger.info("\(TAG) in \(#function): \(call.identifiersForLogs).")
|
||||
|
||||
// TODO make call record.
|
||||
if let callRecord = call.callRecord {
|
||||
assertionFailure("Not expecting callrecord to already be set")
|
||||
callRecord.updateCallType(RPRecentCallTypeIncomingDeclined)
|
||||
} else {
|
||||
let callRecord = TSCall(timestamp: NSDate.ows_millisecondTimeStamp(), withCallNumber: call.remotePhoneNumber, callType: RPRecentCallTypeIncomingDeclined, in: call.thread)
|
||||
callRecord.save()
|
||||
call.callRecord = callRecord
|
||||
}
|
||||
|
||||
// Currently we just handle this as a hangup. But we could offer more descriptive action. e.g. DataChannel message
|
||||
handleLocalHungupCall(call)
|
||||
|
||||
@ -643,6 +643,9 @@
|
||||
/* notification body */
|
||||
"INCOMING_CALL_FROM" = "Incoming call from %@";
|
||||
|
||||
/* info message recorded in conversation history when local user declined a call */
|
||||
"INCOMING_DECLINED_CALL" = "You declined a call";
|
||||
|
||||
/* No comment provided by engineer. */
|
||||
"INCOMING_INCOMPLETE_CALL" = "Incomplete incoming call from";
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user