|
|
@ -442,6 +442,8 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
|
[self sendJpegAction:thread hasCaption:YES],
|
|
|
|
[self sendJpegAction:thread hasCaption:YES],
|
|
|
|
[self sendGifAction:thread hasCaption:NO],
|
|
|
|
[self sendGifAction:thread hasCaption:NO],
|
|
|
|
[self sendGifAction:thread hasCaption:YES],
|
|
|
|
[self sendGifAction:thread hasCaption:YES],
|
|
|
|
|
|
|
|
[self sendLargeGifAction:thread hasCaption:NO],
|
|
|
|
|
|
|
|
[self sendLargeGifAction:thread hasCaption:YES],
|
|
|
|
[self sendMp3Action:thread hasCaption:NO],
|
|
|
|
[self sendMp3Action:thread hasCaption:NO],
|
|
|
|
[self sendMp3Action:thread hasCaption:YES],
|
|
|
|
[self sendMp3Action:thread hasCaption:YES],
|
|
|
|
[self sendMp4Action:thread hasCaption:NO],
|
|
|
|
[self sendMp4Action:thread hasCaption:NO],
|
|
|
@ -470,6 +472,16 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
|
thread:thread];
|
|
|
|
thread:thread];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+ (DebugUIMessagesAction *)sendLargeGifAction:(TSThread *)thread hasCaption:(BOOL)hasCaption
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
OWSAssert(thread);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return [self sendMediaAction:@"Send Large Gif"
|
|
|
|
|
|
|
|
hasCaption:hasCaption
|
|
|
|
|
|
|
|
fakeAssetLoader:[DebugUIMessagesAssetLoader largeGifInstance]
|
|
|
|
|
|
|
|
thread:thread];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
+ (DebugUIMessagesAction *)sendMp3Action:(TSThread *)thread hasCaption:(BOOL)hasCaption
|
|
|
|
+ (DebugUIMessagesAction *)sendMp3Action:(TSThread *)thread hasCaption:(BOOL)hasCaption
|
|
|
|
{
|
|
|
|
{
|
|
|
|
OWSAssert(thread);
|
|
|
|
OWSAssert(thread);
|
|
|
@ -574,6 +586,19 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
|
thread:thread];
|
|
|
|
thread:thread];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+ (DebugUIMessagesAction *)fakeOutgoingLargeGifAction:(TSThread *)thread
|
|
|
|
|
|
|
|
messageState:(TSOutgoingMessageState)messageState
|
|
|
|
|
|
|
|
hasCaption:(BOOL)hasCaption
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
OWSAssert(thread);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return [self fakeOutgoingMediaAction:@"Fake Outgoing Large Gif"
|
|
|
|
|
|
|
|
messageState:messageState
|
|
|
|
|
|
|
|
hasCaption:hasCaption
|
|
|
|
|
|
|
|
fakeAssetLoader:[DebugUIMessagesAssetLoader largeGifInstance]
|
|
|
|
|
|
|
|
thread:thread];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
+ (DebugUIMessagesAction *)fakeOutgoingMp3Action:(TSThread *)thread
|
|
|
|
+ (DebugUIMessagesAction *)fakeOutgoingMp3Action:(TSThread *)thread
|
|
|
|
messageState:(TSOutgoingMessageState)messageState
|
|
|
|
messageState:(TSOutgoingMessageState)messageState
|
|
|
|
hasCaption:(BOOL)hasCaption
|
|
|
|
hasCaption:(BOOL)hasCaption
|
|
|
@ -876,6 +901,19 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
|
thread:thread];
|
|
|
|
thread:thread];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+ (DebugUIMessagesAction *)fakeIncomingLargeGifAction:(TSThread *)thread
|
|
|
|
|
|
|
|
isAttachmentDownloaded:(BOOL)isAttachmentDownloaded
|
|
|
|
|
|
|
|
hasCaption:(BOOL)hasCaption
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
OWSAssert(thread);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return [self fakeIncomingMediaAction:@"Fake Incoming Large Gif"
|
|
|
|
|
|
|
|
isAttachmentDownloaded:isAttachmentDownloaded
|
|
|
|
|
|
|
|
hasCaption:hasCaption
|
|
|
|
|
|
|
|
fakeAssetLoader:[DebugUIMessagesAssetLoader largeGifInstance]
|
|
|
|
|
|
|
|
thread:thread];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
+ (DebugUIMessagesAction *)fakeIncomingMp3Action:(TSThread *)thread
|
|
|
|
+ (DebugUIMessagesAction *)fakeIncomingMp3Action:(TSThread *)thread
|
|
|
|
isAttachmentDownloaded:(BOOL)isAttachmentDownloaded
|
|
|
|
isAttachmentDownloaded:(BOOL)isAttachmentDownloaded
|
|
|
|
hasCaption:(BOOL)hasCaption
|
|
|
|
hasCaption:(BOOL)hasCaption
|
|
|
@ -1182,6 +1220,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
|
[actions addObjectsFromArray:@[
|
|
|
|
[actions addObjectsFromArray:@[
|
|
|
|
// Don't bother with multiple GIF states.
|
|
|
|
// Don't bother with multiple GIF states.
|
|
|
|
[self fakeOutgoingGifAction:thread messageState:TSOutgoingMessageStateSentToService hasCaption:NO],
|
|
|
|
[self fakeOutgoingGifAction:thread messageState:TSOutgoingMessageStateSentToService hasCaption:NO],
|
|
|
|
|
|
|
|
[self fakeOutgoingLargeGifAction:thread messageState:TSOutgoingMessageStateSentToService hasCaption:NO],
|
|
|
|
]];
|
|
|
|
]];
|
|
|
|
if (includeLabels) {
|
|
|
|
if (includeLabels) {
|
|
|
|
[actions addObject:[self fakeOutgoingTextMessageAction:thread
|
|
|
|
[actions addObject:[self fakeOutgoingTextMessageAction:thread
|
|
|
@ -1363,6 +1402,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
|
}
|
|
|
|
}
|
|
|
|
[actions addObjectsFromArray:@[
|
|
|
|
[actions addObjectsFromArray:@[
|
|
|
|
[self fakeIncomingGifAction:thread isAttachmentDownloaded:YES hasCaption:NO],
|
|
|
|
[self fakeIncomingGifAction:thread isAttachmentDownloaded:YES hasCaption:NO],
|
|
|
|
|
|
|
|
[self fakeIncomingLargeGifAction:thread isAttachmentDownloaded:YES hasCaption:NO],
|
|
|
|
]];
|
|
|
|
]];
|
|
|
|
if (includeLabels) {
|
|
|
|
if (includeLabels) {
|
|
|
|
[actions addObject:[self fakeIncomingTextMessageAction:thread text:@"⚠️ Incoming Mp3 ⚠️"]];
|
|
|
|
[actions addObject:[self fakeIncomingTextMessageAction:thread text:@"⚠️ Incoming Mp3 ⚠️"]];
|
|
|
|