Respond to CR.

This commit is contained in:
Matthew Chen 2018-04-02 16:16:21 -04:00
parent fb1f3b5572
commit 4240b517d0
5 changed files with 11 additions and 19 deletions

View file

@ -430,11 +430,6 @@ NSString *NSStringForOWSMessageCellType(OWSMessageCellType cellType)
self.messageCellType = OWSMessageCellType_TextMessage;
self.displayableBodyText = [[DisplayableText alloc] initWithFullText:@"" displayText:@"" isTextTruncated:NO];
}
DDLogInfo(@"%@ --- %@ %@",
self.logTag,
self.interaction.uniqueId,
(self.hasBodyText ? self.displayableBodyText.displayText : @""));
}
- (OWSMessageCellType)messageCellType

View file

@ -284,15 +284,6 @@ typedef NS_ENUM(NSInteger, CellState) { kArchiveState, kInboxState };
}
[self updateBarButtonItems];
dispatch_async(dispatch_get_main_queue(), ^{
NSIndexPath *indexPath = [NSIndexPath indexPathForRow:0 inSection:0];
TSThread *thread = [self threadForIndexPath:indexPath];
if (!thread) {
return;
}
[self presentThread:thread keyboardOnViewAppearing:NO callOnViewAppearing:NO];
});
}
- (void)viewDidAppear:(BOOL)animated

View file

@ -87,7 +87,8 @@ NS_ASSUME_NONNULL_BEGIN
inThread:thread
messageBody:text
attachmentIds:[NSMutableArray new]
expiresInSeconds:(configuration.isEnabled ? configuration.durationSeconds : 0)expireStartedAt:0
expiresInSeconds:(configuration.isEnabled ? configuration.durationSeconds : 0)
expireStartedAt:0
isVoiceMessage:NO
groupMetaMessage:TSGroupMessageNone
quotedMessage:nil];
@ -129,7 +130,8 @@ NS_ASSUME_NONNULL_BEGIN
inThread:thread
messageBody:attachment.captionText
attachmentIds:[NSMutableArray new]
expiresInSeconds:(configuration.isEnabled ? configuration.durationSeconds : 0)expireStartedAt:0
expiresInSeconds:(configuration.isEnabled ? configuration.durationSeconds : 0)
expireStartedAt:0
isVoiceMessage:[attachment isVoiceMessage]
groupMetaMessage:TSGroupMessageNone
quotedMessage:nil];

View file

@ -10,12 +10,15 @@ NS_ASSUME_NONNULL_BEGIN
typedef NS_ENUM(int32_t, TSErrorMessageType) {
TSErrorMessageNoSession,
TSErrorMessageWrongTrustedIdentityKey, // DEPRECATED: We no longer create TSErrorMessageWrongTrustedIdentityKey, but
// DEPRECATED: We no longer create TSErrorMessageWrongTrustedIdentityKey, but
// persisted legacy messages could exist indefinitly.
TSErrorMessageWrongTrustedIdentityKey,
TSErrorMessageInvalidKeyException,
TSErrorMessageMissingKeyId, // unused
// unused
TSErrorMessageMissingKeyId,
TSErrorMessageInvalidMessage,
TSErrorMessageDuplicateMessage, // unused
// unused
TSErrorMessageDuplicateMessage,
TSErrorMessageInvalidVersion,
TSErrorMessageNonBlockingIdentityChange,
TSErrorMessageUnknownContactBlockOffer,

View file

@ -194,6 +194,7 @@ NS_ASSUME_NONNULL_BEGIN
return nil;
}
// TODO: Revisit this value.
const int kMaxThumbnailSizePx = 100;
// Try to resize image to thumbnail if necessary.