Skip to content

Commit

Permalink
Scroll to bottom when scrolled to bottom (#2129)
Browse files Browse the repository at this point in the history
  • Loading branch information
zeitschlag committed Jul 11, 2024
1 parent 7810a34 commit f95afd6
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion deltachat-ios/Chat/ChatViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -436,6 +436,11 @@ class ChatViewController: UITableViewController, UITableViewDropDelegate {
return
}
}

if isLastRowScrolledToBottom() {
scrollToBottom(animated: true)
}

refreshMessages()
updateTitle()
DispatchQueue.main.async {
Expand Down Expand Up @@ -1664,7 +1669,7 @@ class ChatViewController: UITableViewController, UITableViewDropDelegate {
guard let self else { return }
let message = self.dcContext.newMessage(viewType: DC_MSG_TEXT)
message.text = text
if let quoteMessage = quoteMessage {
if let quoteMessage {
message.quoteMessage = quoteMessage
}
self.dcContext.sendMessage(chatId: self.chatId, message: message)
Expand Down

0 comments on commit f95afd6

Please sign in to comment.