Skip to content

Commit

Permalink
adapt to new save_msgs() api
Browse files Browse the repository at this point in the history
  • Loading branch information
r10s committed Jan 16, 2025
1 parent c9a4352 commit ad1312e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion deltachat-ios/Chat/ChatViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1743,7 +1743,7 @@ class ChatViewController: UITableViewController, UITableViewDropDelegate {
} else if message.savedMessageId != 0 {
dcContext.deleteMessage(msgId: message.savedMessageId)
} else {
dcContext.forwardMessage(with: messageIds[indexPath.row], to: dcContext.getChatIdByContactId(contactId: Int(DC_CONTACT_ID_SELF)))
dcContext.saveMessages(with: [messageIds[indexPath.row]])
}
}

Expand Down
4 changes: 4 additions & 0 deletions deltachat-ios/DC/DcContext.swift
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,10 @@ public class DcContext {
dc_forward_msgs(contextPointer, msgIds.compactMap { UInt32($0) }, Int32(msgIds.count), UInt32(chat))
}

public func saveMessages(with msgIds: [Int]) {
dc_save_msgs(contextPointer, msgIds.compactMap { UInt32($0) }, Int32(msgIds.count))

Check failure on line 477 in deltachat-ios/DC/DcContext.swift

View workflow job for this annotation

GitHub Actions / build

cannot find 'dc_save_msgs' in scope
}

public func sendTextInChat(id: Int, message: String) {
dc_send_text_msg(contextPointer, UInt32(id), message)
}
Expand Down

0 comments on commit ad1312e

Please sign in to comment.