You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
session-ios/src/Messages/TSCall.m

34 lines
921 B
Matlab

10 years ago
// Created by Frederic Jacobs on 12/11/14.
// Copyright (c) 2014 Open Whisper Systems. All rights reserved.
#import "TSCall.h"
#import "TSContactThread.h"
10 years ago
@implementation TSCall
- (instancetype)initWithTimestamp:(uint64_t)timeStamp
withCallNumber:(NSString *)contactNumber
callType:(RPRecentCallType)callType
inThread:(TSContactThread *)thread {
self = [super initWithTimestamp:timeStamp inThread:thread];
if (self) {
_callType = callType;
}
return self;
}
- (NSString *)description {
switch (_callType) {
case RPRecentCallTypeIncoming:
return NSLocalizedString(@"INCOMING_CALL", @"");
case RPRecentCallTypeOutgoing:
return NSLocalizedString(@"OUTGOING_CALL", @"");
case RPRecentCallTypeMissed:
return NSLocalizedString(@"MISSED_CALL", @"");
}
}
@end