Commit ce870728 authored by Oliver Wiese's avatar Oliver Wiese
Browse files

change first view when reading a mail

parent 9cb21fae
......@@ -36,13 +36,17 @@ enum ReadPart {
class ReadModel <M: DisplayMail>: ObservableObject {
@Published var dismissView = false
@Published var currentTab = ReadPart.Security.value
@Published var currentTab = ReadPart.Body.value
private var userAction: UserAction?
var mail: M
init(mail: M) {
self.mail = mail
if mail.encryptionState == .UnableToDecrypt ||
mail.warnings.count > 0 {
currentTab = ReadPart.Security.value
}
}
func onDisappear() {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment