Ver Fonte

feat: add sentbox and mvbox threads

dignifiedquire há 6 anos atrás
pai
commit
39bf99d7d7
1 ficheiros alterados com 14 adições e 0 exclusões
  1. 14 0
      deltachat-ios/AppDelegate.swift

+ 14 - 0
deltachat-ios/AppDelegate.swift

@@ -152,6 +152,20 @@ func initCore(withCredentials: Bool, advancedMode:Bool = false, model:Credential
         }
     }
     
+    DispatchQueue.global().async {
+        while true {
+            dc_perform_sentbox_fetch(mailboxPointer)
+            dc_perform_sentbox_idle(mailboxPointer)
+        }
+    }
+    
+    DispatchQueue.global().async {
+        while true {
+            dc_perform_mvbox_fetch(mailboxPointer)
+            dc_perform_mvbox_idle(mailboxPointer)
+        }
+    }
+    
     let _ = dc_open(mailboxPointer, dbfile, nil)
     
     if withCredentials {