瀏覽代碼

undo BasicCell implementation

cyberta 5 年之前
父節點
當前提交
aab5d29e33

+ 0 - 4
deltachat-ios.xcodeproj/project.pbxproj

@@ -98,7 +98,6 @@
 		308FEA50246AB67100FCEAD6 /* FileMessageCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 308FEA4F246AB67100FCEAD6 /* FileMessageCell.swift */; };
 		308FEA50246AB67100FCEAD6 /* FileMessageCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 308FEA4F246AB67100FCEAD6 /* FileMessageCell.swift */; };
 		308FEA52246ABA2700FCEAD6 /* FileMessageSizeCalculator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 308FEA51246ABA2700FCEAD6 /* FileMessageSizeCalculator.swift */; };
 		308FEA52246ABA2700FCEAD6 /* FileMessageSizeCalculator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 308FEA51246ABA2700FCEAD6 /* FileMessageSizeCalculator.swift */; };
 		3095A351237DD1F700AB07F7 /* MediaPicker.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3095A350237DD1F700AB07F7 /* MediaPicker.swift */; };
 		3095A351237DD1F700AB07F7 /* MediaPicker.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3095A350237DD1F700AB07F7 /* MediaPicker.swift */; };
-		30A2039D24A4A1A100BFF51C /* BasicCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 30A2039C24A4A1A100BFF51C /* BasicCell.swift */; };
 		30A2EC36247D72720024ADD8 /* AnimatedImageMessageCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 30A2EC35247D72720024ADD8 /* AnimatedImageMessageCell.swift */; };
 		30A2EC36247D72720024ADD8 /* AnimatedImageMessageCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 30A2EC35247D72720024ADD8 /* AnimatedImageMessageCell.swift */; };
 		30B0ACFA24AB5B99004D5E29 /* SettingsEphemeralMessageController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 30B0ACF924AB5B99004D5E29 /* SettingsEphemeralMessageController.swift */; };
 		30B0ACFA24AB5B99004D5E29 /* SettingsEphemeralMessageController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 30B0ACF924AB5B99004D5E29 /* SettingsEphemeralMessageController.swift */; };
 		30C0D49D237C4908008E2A0E /* CertificateCheckController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 30C0D49C237C4908008E2A0E /* CertificateCheckController.swift */; };
 		30C0D49D237C4908008E2A0E /* CertificateCheckController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 30C0D49C237C4908008E2A0E /* CertificateCheckController.swift */; };
@@ -382,7 +381,6 @@
 		308FEA4F246AB67100FCEAD6 /* FileMessageCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileMessageCell.swift; sourceTree = "<group>"; };
 		308FEA4F246AB67100FCEAD6 /* FileMessageCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileMessageCell.swift; sourceTree = "<group>"; };
 		308FEA51246ABA2700FCEAD6 /* FileMessageSizeCalculator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileMessageSizeCalculator.swift; sourceTree = "<group>"; };
 		308FEA51246ABA2700FCEAD6 /* FileMessageSizeCalculator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileMessageSizeCalculator.swift; sourceTree = "<group>"; };
 		3095A350237DD1F700AB07F7 /* MediaPicker.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MediaPicker.swift; sourceTree = "<group>"; };
 		3095A350237DD1F700AB07F7 /* MediaPicker.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MediaPicker.swift; sourceTree = "<group>"; };
-		30A2039C24A4A1A100BFF51C /* BasicCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BasicCell.swift; sourceTree = "<group>"; };
 		30A2EC35247D72720024ADD8 /* AnimatedImageMessageCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AnimatedImageMessageCell.swift; sourceTree = "<group>"; };
 		30A2EC35247D72720024ADD8 /* AnimatedImageMessageCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AnimatedImageMessageCell.swift; sourceTree = "<group>"; };
 		30AC265E237F1807002A943F /* AvatarHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AvatarHelper.swift; sourceTree = "<group>"; };
 		30AC265E237F1807002A943F /* AvatarHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AvatarHelper.swift; sourceTree = "<group>"; };
 		30B0ACF924AB5B99004D5E29 /* SettingsEphemeralMessageController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SettingsEphemeralMessageController.swift; sourceTree = "<group>"; };
 		30B0ACF924AB5B99004D5E29 /* SettingsEphemeralMessageController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SettingsEphemeralMessageController.swift; sourceTree = "<group>"; };
@@ -985,7 +983,6 @@
 				AEFBE22E23FEF23D0045327A /* ProviderInfoCell.swift */,
 				AEFBE22E23FEF23D0045327A /* ProviderInfoCell.swift */,
 				AEB54C7E246DBA610004624C /* FlexLabel.swift */,
 				AEB54C7E246DBA610004624C /* FlexLabel.swift */,
 				AED62BCD247687E6009E220D /* LocationStreamingIndicator.swift */,
 				AED62BCD247687E6009E220D /* LocationStreamingIndicator.swift */,
-				30A2039C24A4A1A100BFF51C /* BasicCell.swift */,
 			);
 			);
 			path = View;
 			path = View;
 			sourceTree = "<group>";
 			sourceTree = "<group>";
@@ -1413,7 +1410,6 @@
 				302B84C6239676F0001C261F /* AvatarHelper.swift in Sources */,
 				302B84C6239676F0001C261F /* AvatarHelper.swift in Sources */,
 				AE77838D23E32ED20093EABD /* ContactDetailViewModel.swift in Sources */,
 				AE77838D23E32ED20093EABD /* ContactDetailViewModel.swift in Sources */,
 				305961E62346125100C80F33 /* LocationMessageSnapshotOptions.swift in Sources */,
 				305961E62346125100C80F33 /* LocationMessageSnapshotOptions.swift in Sources */,
-				30A2039D24A4A1A100BFF51C /* BasicCell.swift in Sources */,
 				AEE6EC3F2282C59C00EDC689 /* GroupMembersViewController.swift in Sources */,
 				AEE6EC3F2282C59C00EDC689 /* GroupMembersViewController.swift in Sources */,
 				B26B3BC7236DC3DC008ED35A /* SwitchCell.swift in Sources */,
 				B26B3BC7236DC3DC008ED35A /* SwitchCell.swift in Sources */,
 				AEE700252438E0E500D6992E /* ProgressAlertHandler.swift in Sources */,
 				AEE700252438E0E500D6992E /* ProgressAlertHandler.swift in Sources */,

+ 21 - 21
deltachat-ios/Controller/AccountSetupController.swift

@@ -100,9 +100,9 @@ class AccountSetupController: UITableViewController, ProgressAlertHandler {
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var restoreCell: BasicCell = {
-        let cell = BasicCell(style: .value1, reuseIdentifier: nil)
-        cell.title.text = String.localized("import_backup_title")
+    private lazy var restoreCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("import_backup_title")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         cell.tag = tagRestoreCell
         cell.tag = tagRestoreCell
         return cell
         return cell
@@ -116,9 +116,9 @@ class AccountSetupController: UITableViewController, ProgressAlertHandler {
         return cell
         return cell
     }()
     }()
 
 
-    lazy var advancedShowCell: BasicCell = {
-        let cell = BasicCell(style: .value1, reuseIdentifier: nil)
-        cell.title.text = String.localized("menu_advanced")
+    lazy var advancedShowCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("menu_advanced")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         cell.tag = tagAdvancedCell
         cell.tag = tagAdvancedCell
         return cell
         return cell
@@ -172,12 +172,12 @@ class AccountSetupController: UITableViewController, ProgressAlertHandler {
         return cell
         return cell
     }()
     }()
 
 
-    lazy var imapSecurityCell: BasicCell = {
+    lazy var imapSecurityCell: UITableViewCell = {
         let text = "\(dcContext.getImapSecurity())"
         let text = "\(dcContext.getImapSecurity())"
-        let cell = BasicCell(style: .value1, reuseIdentifier: nil)
-        cell.title.text = String.localized("login_imap_security")
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("login_imap_security")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
-        cell.value.text = "\(dcContext.getImapSecurity())"
+        cell.detailTextLabel?.text = "\(dcContext.getImapSecurity())"
         cell.selectionStyle = .none
         cell.selectionStyle = .none
         cell.tag = tagImapSecurityCell
         cell.tag = tagImapSecurityCell
         return cell
         return cell
@@ -233,22 +233,22 @@ class AccountSetupController: UITableViewController, ProgressAlertHandler {
         return cell
         return cell
     }()
     }()
 
 
-    lazy var smtpSecurityCell: BasicCell = {
+    lazy var smtpSecurityCell: UITableViewCell = {
         let security = "\(dcContext.getSmtpSecurity())"
         let security = "\(dcContext.getSmtpSecurity())"
-        let cell = BasicCell(style: .value1, reuseIdentifier: nil)
-        cell.title.text = String.localized("login_smtp_security")
-        cell.value.text = security
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("login_smtp_security")
+        cell.detailTextLabel?.text = security
         cell.tag = tagSmtpSecurityCell
         cell.tag = tagSmtpSecurityCell
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         cell.selectionStyle = .none
         cell.selectionStyle = .none
         return cell
         return cell
     }()
     }()
 
 
-    lazy var certCheckCell: BasicCell = {
+    lazy var certCheckCell: UITableViewCell = {
         let certCheckType = CertificateCheckController.ValueConverter.convertHexToString(value: dcContext.certificateChecks)
         let certCheckType = CertificateCheckController.ValueConverter.convertHexToString(value: dcContext.certificateChecks)
-        let cell = BasicCell(style: .value1, reuseIdentifier: nil)
-        cell.title.text = String.localized("login_certificate_checks")
-        cell.value.text = certCheckType
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("login_certificate_checks")
+        cell.detailTextLabel?.text = certCheckType
         cell.tag = tagCertCheckCell
         cell.tag = tagCertCheckCell
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         cell.selectionStyle = .none
         cell.selectionStyle = .none
@@ -776,9 +776,9 @@ class AccountSetupController: UITableViewController, ProgressAlertHandler {
     }
     }
 
 
     private func initSelectionCells() {
     private func initSelectionCells() {
-        smtpSecurityCell.value.text = SecurityConverter.convertHexToString(type: .SMTPSecurity, hex: dcContext.getSmtpSecurity())
-        imapSecurityCell.value.text = SecurityConverter.convertHexToString(type: .IMAPSecurity, hex: dcContext.getImapSecurity())
-        certCheckCell.value.text = CertificateCheckController.ValueConverter.convertHexToString(value: dcContext.certificateChecks)
+        smtpSecurityCell.textLabel?.text = SecurityConverter.convertHexToString(type: .SMTPSecurity, hex: dcContext.getSmtpSecurity())
+        imapSecurityCell.textLabel?.text = SecurityConverter.convertHexToString(type: .IMAPSecurity, hex: dcContext.getImapSecurity())
+        certCheckCell.textLabel?.text = CertificateCheckController.ValueConverter.convertHexToString(value: dcContext.certificateChecks)
     }
     }
 
 
     private func resignFirstResponderOnAllCells() {
     private func resignFirstResponderOnAllCells() {

+ 9 - 9
deltachat-ios/Controller/ContactDetailViewController.swift

@@ -26,9 +26,9 @@ class ContactDetailViewController: UITableViewController {
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var ephemeralMessagesCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
-        cell.title.text = String.localized("ephemeral_messages")
+    private lazy var ephemeralMessagesCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("ephemeral_messages")
         cell.selectionStyle = .none
         cell.selectionStyle = .none
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         return cell
         return cell
@@ -66,9 +66,9 @@ class ContactDetailViewController: UITableViewController {
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var galleryCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
-        cell.title.text = String.localized("gallery")
+    private lazy var galleryCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("gallery")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         if viewModel.chatId == 0 {
         if viewModel.chatId == 0 {
             cell.isUserInteractionEnabled = false
             cell.isUserInteractionEnabled = false
@@ -77,9 +77,9 @@ class ContactDetailViewController: UITableViewController {
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var documentsCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
-        cell.title.text = String.localized("documents")
+    private lazy var documentsCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("documents")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         if viewModel.chatId == 0 {
         if viewModel.chatId == 0 {
             cell.isUserInteractionEnabled = false
             cell.isUserInteractionEnabled = false

+ 3 - 3
deltachat-ios/Controller/EditSettingsController.swift

@@ -31,9 +31,9 @@ class EditSettingsController: UITableViewController, MediaPickerDelegate {
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var accountSettingsCell: BasicCell = {
-        let cell = BasicCell(style: .value1, reuseIdentifier: nil)
-        cell.title.text = String.localized("pref_password_and_account_settings")
+    private lazy var accountSettingsCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("pref_password_and_account_settings")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         cell.tag = tagAccountSettingsCell
         cell.tag = tagAccountSettingsCell
         return cell
         return cell

+ 9 - 9
deltachat-ios/Controller/GroupChatDetailViewController.swift

@@ -90,9 +90,9 @@ class GroupChatDetailViewController: UIViewController {
         return header
         return header
     }()
     }()
 
 
-    private lazy var ephemeralMessagesCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
-        cell.title.text = String.localized("ephemeral_messages")
+    private lazy var ephemeralMessagesCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("ephemeral_messages")
         cell.selectionStyle = .none
         cell.selectionStyle = .none
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         return cell
         return cell
@@ -131,16 +131,16 @@ class GroupChatDetailViewController: UIViewController {
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var galleryCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
-        cell.title.text = String.localized("gallery")
+    private lazy var galleryCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("gallery")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var documentsCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
-        cell.title.text = String.localized("documents")
+    private lazy var documentsCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
+        cell.textLabel?.text = String.localized("documents")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         return cell
         return cell
     }()
     }()

+ 30 - 30
deltachat-ios/Controller/SettingsController.swift

@@ -45,27 +45,27 @@ internal final class SettingsViewController: UITableViewController, ProgressAler
         return cell
         return cell
     }()
     }()
 
 
-    private var contactRequestCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private var contactRequestCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
         cell.tag = CellTags.contactRequest.rawValue
         cell.tag = CellTags.contactRequest.rawValue
-        cell.title.text = String.localized("menu_deaddrop")
+        cell.textLabel?.text = String.localized("menu_deaddrop")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var showEmailsCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private lazy var showEmailsCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
         cell.tag = CellTags.showEmails.rawValue
         cell.tag = CellTags.showEmails.rawValue
-        cell.title.text = String.localized("pref_show_emails")
+        cell.textLabel?.text = String.localized("pref_show_emails")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
-        cell.value.text = SettingsClassicViewController.getValString(val: dcContext.showEmails)
+        cell.detailTextLabel?.text = SettingsClassicViewController.getValString(val: dcContext.showEmails)
         return cell
         return cell
     }()
     }()
 
 
-    private var blockedContactsCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private var blockedContactsCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
         cell.tag = CellTags.blockedContacts.rawValue
         cell.tag = CellTags.blockedContacts.rawValue
-        cell.title.text = String.localized("pref_blocked_contacts")
+        cell.textLabel?.text = String.localized("pref_blocked_contacts")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
         return cell
         return cell
     }()
     }()
@@ -80,21 +80,21 @@ internal final class SettingsViewController: UITableViewController, ProgressAler
         }
         }
     }
     }
 
 
-    private lazy var autodelCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private lazy var autodelCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
         cell.tag = CellTags.autodel.rawValue
         cell.tag = CellTags.autodel.rawValue
-        cell.title.text = String.localized("delete_old_messages")
+        cell.textLabel?.text = String.localized("delete_old_messages")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
-        cell.value.text = autodelSummary()
+        cell.detailTextLabel?.text = autodelSummary()
         return cell
         return cell
     }()
     }()
 
 
-    private lazy var mediaQualityCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private lazy var mediaQualityCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .value1, reuseIdentifier: nil)
         cell.tag = CellTags.mediaQuality.rawValue
         cell.tag = CellTags.mediaQuality.rawValue
-        cell.title.text = String.localized("pref_outgoing_media_quality")
+        cell.textLabel?.text = String.localized("pref_outgoing_media_quality")
         cell.accessoryType = .disclosureIndicator
         cell.accessoryType = .disclosureIndicator
-        cell.value.text = MediaQualityController.getValString(val: dcContext.getConfigInt("media_quality"))
+        cell.detailTextLabel?.text = MediaQualityController.getValString(val: dcContext.getConfigInt("media_quality"))
         return cell
         return cell
     }()
     }()
 
 
@@ -105,10 +105,10 @@ internal final class SettingsViewController: UITableViewController, ProgressAler
         return switchControl
         return switchControl
     }()
     }()
 
 
-    private lazy var notificationCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private lazy var notificationCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
         cell.tag = CellTags.notifications.rawValue
         cell.tag = CellTags.notifications.rawValue
-        cell.title.text = String.localized("pref_notifications")
+        cell.textLabel?.text = String.localized("pref_notifications")
         cell.accessoryView = notificationSwitch
         cell.accessoryView = notificationSwitch
         cell.selectionStyle = .none
         cell.selectionStyle = .none
         return cell
         return cell
@@ -121,10 +121,10 @@ internal final class SettingsViewController: UITableViewController, ProgressAler
         return switchControl
         return switchControl
     }()
     }()
 
 
-    private lazy var receiptConfirmationCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private lazy var receiptConfirmationCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
         cell.tag = CellTags.receiptConfirmation.rawValue
         cell.tag = CellTags.receiptConfirmation.rawValue
-        cell.title.text = String.localized("pref_read_receipts")
+        cell.textLabel?.text = String.localized("pref_read_receipts")
         cell.accessoryView = receiptConfirmationSwitch
         cell.accessoryView = receiptConfirmationSwitch
         cell.selectionStyle = .none
         cell.selectionStyle = .none
         return cell
         return cell
@@ -137,10 +137,10 @@ internal final class SettingsViewController: UITableViewController, ProgressAler
         return switchControl
         return switchControl
     }()
     }()
 
 
-    private lazy var autocryptPreferencesCell: BasicCell = {
-        let cell = BasicCell(style: .default, reuseIdentifier: nil)
+    private lazy var autocryptPreferencesCell: UITableViewCell = {
+        let cell = UITableViewCell(style: .default, reuseIdentifier: nil)
         cell.tag = CellTags.autocryptPreferences.rawValue
         cell.tag = CellTags.autocryptPreferences.rawValue
-        cell.title.text = String.localized("autocrypt_prefer_e2ee")
+        cell.textLabel?.text = String.localized("autocrypt_prefer_e2ee")
         cell.accessoryView = autocryptSwitch
         cell.accessoryView = autocryptSwitch
         cell.selectionStyle = .none
         cell.selectionStyle = .none
         return cell
         return cell
@@ -437,9 +437,9 @@ internal final class SettingsViewController: UITableViewController, ProgressAler
     // MARK: - updates
     // MARK: - updates
     private func updateCells() {
     private func updateCells() {
         profileCell.updateCell(cellViewModel: ProfileViewModell(context: dcContext))
         profileCell.updateCell(cellViewModel: ProfileViewModell(context: dcContext))
-        showEmailsCell.value.text = SettingsClassicViewController.getValString(val: dcContext.showEmails)
-        mediaQualityCell.value.text = MediaQualityController.getValString(val: dcContext.getConfigInt("media_quality"))
-        autodelCell.value.text = autodelSummary()
+        showEmailsCell.detailTextLabel?.text = SettingsClassicViewController.getValString(val: dcContext.showEmails)
+        mediaQualityCell.detailTextLabel?.text = MediaQualityController.getValString(val: dcContext.getConfigInt("media_quality"))
+        autodelCell.detailTextLabel?.text = autodelSummary()
     }
     }
 
 
     // MARK: - coordinator
     // MARK: - coordinator

+ 0 - 104
deltachat-ios/View/BasicCell.swift

@@ -1,104 +0,0 @@
-import Foundation
-import UIKit
-
-class BasicCell: UITableViewCell {
-
-    static let reuseIdentifier = "basic_cell_reuse_identifier"
-
-    private var fontSize: CGFloat {
-        return UIFont.preferredFont(forTextStyle: .body).pointSize
-    }
-    private let maxFontSizeHorizontalLayout: CGFloat = 24
-    private var layoutConstraints: [NSLayoutConstraint] = []
-    var margin: CGFloat = 12
-
-    public lazy var title: UILabel = {
-        let label = UILabel()
-        label.font = .preferredFont(forTextStyle: .body)
-        label.adjustsFontForContentSizeCategory = true
-        label.lineBreakMode = .byTruncatingTail
-        label.translatesAutoresizingMaskIntoConstraints = false
-        label.setContentCompressionResistancePriority(UILayoutPriority(rawValue: 10), for: NSLayoutConstraint.Axis.horizontal)
-        return label
-    }()
-
-    public lazy var value: UILabel = {
-        let label = UILabel()
-        label.font = .preferredFont(forTextStyle: .body)
-        label.adjustsFontForContentSizeCategory = true
-        label.textColor = .systemGray
-        label.lineBreakMode = .byTruncatingTail
-        label.translatesAutoresizingMaskIntoConstraints = false
-        label.setContentHuggingPriority(.defaultHigh, for: NSLayoutConstraint.Axis.horizontal)
-        label.setContentCompressionResistancePriority(UILayoutPriority(rawValue: 1), for: NSLayoutConstraint.Axis.horizontal)
-        label.textAlignment = .right
-        return label
-    }()
-
-    public lazy var stackView: UIStackView = {
-        let view = UIStackView()
-        view.translatesAutoresizingMaskIntoConstraints = false
-        view.clipsToBounds = true
-
-        view.addArrangedSubview(title)
-        view.addArrangedSubview(value)
-        view.axis = .horizontal
-        view.spacing = 10
-        return view
-    }()
-
-    override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
-        super.init(style: style, reuseIdentifier: reuseIdentifier)
-        setupSubviews()
-    }
-
-    required init?(coder _: NSCoder) {
-        fatalError("init(coder:) has not been implemented")
-    }
-
-
-    private func setupSubviews() {
-        contentView.addSubview(stackView)
-        contentView.removeConstraints(contentView.constraints)
-               contentView.addConstraints([
-                   stackView.constraintAlignLeadingTo(contentView, paddingLeading: margin),
-                   stackView.constraintAlignTopTo(contentView, paddingTop: margin),
-                   stackView.constraintAlignBottomTo(contentView, paddingBottom: margin),
-                   stackView.constraintAlignTrailingTo(/*accessoryView ??*/ contentView, paddingTrailing: margin)
-               ])
-        updateViews()
-    }
-
-    override func traitCollectionDidChange(_ previousTraitCollection: UITraitCollection?) {
-        if previousTraitCollection?.preferredContentSizeCategory !=
-            traitCollection.preferredContentSizeCategory {
-            updateViews()
-        }
-    }
-
-    public func updateViews() {
-        if fontSize <= maxFontSizeHorizontalLayout {
-            title.numberOfLines = 1
-            value.numberOfLines = 1
-            value.textAlignment = .right
-            stackView.axis = .horizontal
-            stackView.spacing = (value.text?.count ?? 0) == 0 ? 0 : 10
-
-        } else {
-            title.numberOfLines = 0
-            value.numberOfLines = 0
-            value.textAlignment = .left
-            stackView.axis = .vertical
-            stackView.spacing = 0
-        }
-    }
-
-    override func prepareForReuse() {
-        super.prepareForReuse()
-        title.text = nil
-        value.text = nil
-        title.attributedText = nil
-        value.attributedText = nil
-
-    }
-}