Always clear message drafts after sending a text message.
// FREEBIE
This commit is contained in:
parent
50b1f420b5
commit
29dd62a19a
|
@ -1509,6 +1509,7 @@ typedef enum : NSUInteger {
|
|||
{
|
||||
[self toggleDefaultKeyboard];
|
||||
}
|
||||
[self clearDraft];
|
||||
[self finishSendingMessage];
|
||||
}
|
||||
}
|
||||
|
@ -3349,11 +3350,19 @@ typedef enum : NSUInteger {
|
|||
__block NSString *currentDraft = self.inputToolbar.contentView.textView.text;
|
||||
|
||||
[self.editingDatabaseConnection asyncReadWriteWithBlock:^(YapDatabaseReadWriteTransaction *transaction) {
|
||||
[thread setDraft:currentDraft transaction:transaction];
|
||||
[thread setDraft:currentDraft transaction:transaction];
|
||||
}];
|
||||
}
|
||||
}
|
||||
|
||||
- (void)clearDraft
|
||||
{
|
||||
__block TSThread *thread = _thread;
|
||||
[self.editingDatabaseConnection asyncReadWriteWithBlock:^(YapDatabaseReadWriteTransaction *transaction) {
|
||||
[thread setDraft:@"" transaction:transaction];
|
||||
}];
|
||||
}
|
||||
|
||||
#pragma mark Unread Badge
|
||||
|
||||
- (void)updateBackButtonUnreadCount
|
||||
|
|
Loading…
Reference in New Issue