create interaction in thread when missing call due to changed identity
// FREEBIE
This commit is contained in:
parent
c8a444d931
commit
1a3204bf46
4
Podfile
4
Podfile
|
@ -5,8 +5,8 @@ target 'Signal' do
|
||||||
pod 'SocketRocket', :git => 'https://github.com/facebook/SocketRocket.git'
|
pod 'SocketRocket', :git => 'https://github.com/facebook/SocketRocket.git'
|
||||||
pod 'AxolotlKit', git: 'https://github.com/WhisperSystems/SignalProtocolKit.git'
|
pod 'AxolotlKit', git: 'https://github.com/WhisperSystems/SignalProtocolKit.git'
|
||||||
#pod 'AxolotlKit', path: '../SignalProtocolKit'
|
#pod 'AxolotlKit', path: '../SignalProtocolKit'
|
||||||
pod 'SignalServiceKit', git: 'https://github.com/WhisperSystems/SignalServiceKit.git'
|
#pod 'SignalServiceKit', git: 'https://github.com/WhisperSystems/SignalServiceKit.git'
|
||||||
#pod 'SignalServiceKit', path: '../SignalServiceKit'
|
pod 'SignalServiceKit', path: '../SignalServiceKit'
|
||||||
pod 'OpenSSL'
|
pod 'OpenSSL'
|
||||||
pod 'JSQMessagesViewController', git: 'https://github.com/WhisperSystems/JSQMessagesViewController.git', branch: 'mkirk/position-edit-menu'
|
pod 'JSQMessagesViewController', git: 'https://github.com/WhisperSystems/JSQMessagesViewController.git', branch: 'mkirk/position-edit-menu'
|
||||||
#pod 'JSQMessagesViewController' path: '../JSQMessagesViewController'
|
#pod 'JSQMessagesViewController' path: '../JSQMessagesViewController'
|
||||||
|
|
|
@ -114,7 +114,7 @@ DEPENDENCIES:
|
||||||
- OpenSSL
|
- OpenSSL
|
||||||
- PureLayout
|
- PureLayout
|
||||||
- Reachability
|
- Reachability
|
||||||
- SignalServiceKit (from `https://github.com/WhisperSystems/SignalServiceKit.git`)
|
- SignalServiceKit (from `../SignalServiceKit`)
|
||||||
- SocketRocket (from `https://github.com/facebook/SocketRocket.git`)
|
- SocketRocket (from `https://github.com/facebook/SocketRocket.git`)
|
||||||
|
|
||||||
EXTERNAL SOURCES:
|
EXTERNAL SOURCES:
|
||||||
|
@ -124,7 +124,7 @@ EXTERNAL SOURCES:
|
||||||
:branch: mkirk/position-edit-menu
|
:branch: mkirk/position-edit-menu
|
||||||
:git: https://github.com/WhisperSystems/JSQMessagesViewController.git
|
:git: https://github.com/WhisperSystems/JSQMessagesViewController.git
|
||||||
SignalServiceKit:
|
SignalServiceKit:
|
||||||
:git: https://github.com/WhisperSystems/SignalServiceKit.git
|
:path: "../SignalServiceKit"
|
||||||
SocketRocket:
|
SocketRocket:
|
||||||
:git: https://github.com/facebook/SocketRocket.git
|
:git: https://github.com/facebook/SocketRocket.git
|
||||||
|
|
||||||
|
@ -135,9 +135,6 @@ CHECKOUT OPTIONS:
|
||||||
JSQMessagesViewController:
|
JSQMessagesViewController:
|
||||||
:commit: 7054e4b13ee5bcd6d524adb6dc9a726e8c466308
|
:commit: 7054e4b13ee5bcd6d524adb6dc9a726e8c466308
|
||||||
:git: https://github.com/WhisperSystems/JSQMessagesViewController.git
|
:git: https://github.com/WhisperSystems/JSQMessagesViewController.git
|
||||||
SignalServiceKit:
|
|
||||||
:commit: 435f13f2ffc4631aeb282fc02a8a3305f6e8645b
|
|
||||||
:git: https://github.com/WhisperSystems/SignalServiceKit.git
|
|
||||||
SocketRocket:
|
SocketRocket:
|
||||||
:commit: 877ac7438be3ad0b45ef5ca3969574e4b97112bf
|
:commit: 877ac7438be3ad0b45ef5ca3969574e4b97112bf
|
||||||
:git: https://github.com/facebook/SocketRocket.git
|
:git: https://github.com/facebook/SocketRocket.git
|
||||||
|
@ -164,6 +161,6 @@ SPEC CHECKSUMS:
|
||||||
UnionFind: c33be5adb12983981d6e827ea94fc7f9e370f52d
|
UnionFind: c33be5adb12983981d6e827ea94fc7f9e370f52d
|
||||||
YapDatabase: cd911121580ff16675f65ad742a9eb0ab4d9e266
|
YapDatabase: cd911121580ff16675f65ad742a9eb0ab4d9e266
|
||||||
|
|
||||||
PODFILE CHECKSUM: 48e80d7f1e049bbf544a689fdfdf33e8196c640a
|
PODFILE CHECKSUM: 6f9ef5d9fa17469569e127a9f5719dafa11631b9
|
||||||
|
|
||||||
COCOAPODS: 1.2.1
|
COCOAPODS: 1.2.1
|
||||||
|
|
|
@ -18,6 +18,7 @@ typedef enum : NSUInteger {
|
||||||
// kGroupUpdateJoin has been deprecated.
|
// kGroupUpdateJoin has been deprecated.
|
||||||
kGroupUpdateLeft = 7,
|
kGroupUpdateLeft = 7,
|
||||||
kGroupUpdate = 8,
|
kGroupUpdate = 8,
|
||||||
|
kCallMissedBecauseOfChangedIdentity = 9,
|
||||||
} CallStatus;
|
} CallStatus;
|
||||||
|
|
||||||
@interface OWSCall : NSObject <OWSMessageData>
|
@interface OWSCall : NSObject <OWSMessageData>
|
||||||
|
|
|
@ -54,6 +54,9 @@ NS_ASSUME_NONNULL_BEGIN
|
||||||
case RPRecentCallTypeIncomingIncomplete:
|
case RPRecentCallTypeIncomingIncomplete:
|
||||||
status = kCallIncomingIncomplete;
|
status = kCallIncomingIncomplete;
|
||||||
break;
|
break;
|
||||||
|
case RPRecentCallTypeMissedBecauseOfChangedIdentity:
|
||||||
|
status = kCallMissedBecauseOfChangedIdentity;
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
status = kCallIncoming;
|
status = kCallIncoming;
|
||||||
break;
|
break;
|
||||||
|
@ -77,6 +80,9 @@ NS_ASSUME_NONNULL_BEGIN
|
||||||
case kCallOutgoingIncomplete:
|
case kCallOutgoingIncomplete:
|
||||||
detailString = [NSString stringWithFormat:NSLocalizedString(@"MSGVIEW_YOU_TRIED_TO_CALL", nil), name];
|
detailString = [NSString stringWithFormat:NSLocalizedString(@"MSGVIEW_YOU_TRIED_TO_CALL", nil), name];
|
||||||
break;
|
break;
|
||||||
|
case kCallMissedBecauseOfChangedIdentity:
|
||||||
|
detailString = [NSString
|
||||||
|
stringWithFormat:NSLocalizedString(@"MSGVIEW_MISSED_CALL_BECAUSE_OF_CHANGED_IDENTITY", nil), name];
|
||||||
default:
|
default:
|
||||||
detailString = @"";
|
detailString = @"";
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -576,6 +576,10 @@ NS_ASSUME_NONNULL_BEGIN
|
||||||
withCallNumber:@"+19174054215"
|
withCallNumber:@"+19174054215"
|
||||||
callType:RPRecentCallTypeMissed
|
callType:RPRecentCallTypeMissed
|
||||||
inThread:contactThread]];
|
inThread:contactThread]];
|
||||||
|
[result addObject:[[TSCall alloc] initWithTimestamp:[NSDate ows_millisecondTimeStamp]
|
||||||
|
withCallNumber:@"+19174054215"
|
||||||
|
callType:RPRecentCallTypeMissedBecauseOfChangedIdentity
|
||||||
|
inThread:contactThread]];
|
||||||
[result addObject:[[TSCall alloc] initWithTimestamp:[NSDate ows_millisecondTimeStamp]
|
[result addObject:[[TSCall alloc] initWithTimestamp:[NSDate ows_millisecondTimeStamp]
|
||||||
withCallNumber:@"+19174054215"
|
withCallNumber:@"+19174054215"
|
||||||
callType:RPRecentCallTypeOutgoingIncomplete
|
callType:RPRecentCallTypeOutgoingIncomplete
|
||||||
|
|
|
@ -486,6 +486,14 @@ protocol CallServiceObserver: class {
|
||||||
self.notificationsAdapter.presentMissedCallBecauseOfNoLongerVerifiedIdentity(call: newCall, callerName: callerName)
|
self.notificationsAdapter.presentMissedCallBecauseOfNoLongerVerifiedIdentity(call: newCall, callerName: callerName)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let callRecord = TSCall(timestamp: NSDate.ows_millisecondTimeStamp(),
|
||||||
|
withCallNumber: thread.contactIdentifier(),
|
||||||
|
callType: RPRecentCallTypeMissedBecauseOfChangedIdentity,
|
||||||
|
in: thread)
|
||||||
|
assert(newCall.callRecord == nil)
|
||||||
|
newCall.callRecord = callRecord
|
||||||
|
callRecord.save()
|
||||||
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -616,6 +616,9 @@
|
||||||
/* No comment provided by engineer. */
|
/* No comment provided by engineer. */
|
||||||
"INCOMING_INCOMPLETE_CALL" = "Incomplete incoming call from";
|
"INCOMING_INCOMPLETE_CALL" = "Incomplete incoming call from";
|
||||||
|
|
||||||
|
/* info message text shown in conversation view */
|
||||||
|
"INFO_MESSAGE_MISSED_CALL_DUE_TO_CHANGED_IDENITY" = "Missed call because their safety number has changed.";
|
||||||
|
|
||||||
/* Message for the alert indicating that an audio file is invalid. */
|
/* Message for the alert indicating that an audio file is invalid. */
|
||||||
"INVALID_AUDIO_FILE_ALERT_ERROR_MESSAGE" = "Invalid audio file.";
|
"INVALID_AUDIO_FILE_ALERT_ERROR_MESSAGE" = "Invalid audio file.";
|
||||||
|
|
||||||
|
@ -756,6 +759,9 @@
|
||||||
Alert title when camera is not authorized */
|
Alert title when camera is not authorized */
|
||||||
"MISSING_CAMERA_PERMISSION_TITLE" = "Signal needs to access your camera.";
|
"MISSING_CAMERA_PERMISSION_TITLE" = "Signal needs to access your camera.";
|
||||||
|
|
||||||
|
/* No comment provided by engineer. */
|
||||||
|
"MSGVIEW_MISSED_CALL_BECAUSE_OF_CHANGED_IDENTITY" = "Missed call because their safety number has changed.";
|
||||||
|
|
||||||
/* notification title. Embeds {{caller's name or phone number}} */
|
/* notification title. Embeds {{caller's name or phone number}} */
|
||||||
"MSGVIEW_MISSED_CALL_WITH_NAME" = "Missed call from %@.";
|
"MSGVIEW_MISSED_CALL_WITH_NAME" = "Missed call from %@.";
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue