Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide message-bar when forwarding #2443

Merged
merged 2 commits into from
Dec 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Delta Chat iOS Changelog

## Unreleased

- Don't show message-input when forwarding (#2435)

## v1.50.3

- Don't change order of proxies when selecting a new one (#2414)
Expand Down
26 changes: 13 additions & 13 deletions deltachat-ios/Chat/ChatViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,7 @@ class ChatViewController: UITableViewController, UITableViewDropDelegate {

if RelayHelper.shared.isForwarding() {
if RelayHelper.shared.forwardIds != nil {
resignFirstResponder()
askToForwardMessage()
} else if let vcardData = RelayHelper.shared.forwardVCardData,
let vcardURL = prepareVCardData(vcardData) {
Expand Down Expand Up @@ -1355,22 +1356,21 @@ class ChatViewController: UITableViewController, UITableViewDropDelegate {
}

private func askToForwardMessage() {
let chat = dcContext.getChat(chatId: self.chatId)
let chat = dcContext.getChat(chatId: chatId)
if chat.isSelfTalk {
RelayHelper.shared.forwardIdsAndFinishRelaying(to: self.chatId)
RelayHelper.shared.forwardIdsAndFinishRelaying(to: chatId)
refreshMessages()
} else {
DispatchQueue.main.async { [weak self] in
self?.confirmationAlert(title: String.localizedStringWithFormat(String.localized("ask_forward"), chat.name),
actionTitle: String.localized("menu_forward"),
actionHandler: { [weak self] _ in
guard let self else { return }
RelayHelper.shared.forwardIdsAndFinishRelaying(to: self.chatId)
},
cancelHandler: { [weak self] _ in
self?.navigationController?.popViewController(animated: true)
})
}
confirmationAlert(title: String.localizedStringWithFormat(String.localized("ask_forward"), chat.name),
actionTitle: String.localized("menu_forward"),
actionHandler: { [weak self] _ in
guard let self else { return }
RelayHelper.shared.forwardIdsAndFinishRelaying(to: self.chatId)
self.becomeFirstResponder()
},
cancelHandler: { [weak self] _ in
self?.navigationController?.popViewController(animated: true)
})
}
}

Expand Down
Loading