|
@@ -154,7 +154,9 @@ extension ChatListController: UITableViewDataSource, UITableViewDelegate {
|
|
|
}
|
|
|
|
|
|
let cell: ContactCell
|
|
|
- if let c = tableView.dequeueReusableCell(withIdentifier: "ChatCell") as? ContactCell {
|
|
|
+ if chatId == DC_CHAT_ID_DEADDROP {
|
|
|
+ cell = getDeaddropCell(tableView)
|
|
|
+ } else if let c = tableView.dequeueReusableCell(withIdentifier: "ChatCell") as? ContactCell {
|
|
|
cell = c
|
|
|
} else {
|
|
|
cell = ContactCell(style: .default, reuseIdentifier: "ChatCell")
|
|
@@ -168,7 +170,6 @@ extension ChatListController: UITableViewDataSource, UITableViewDelegate {
|
|
|
NSAttributedString(string: chat.name, attributes: [ .font: UIFont.systemFont(ofSize: 16, weight: .bold) ]) :
|
|
|
NSAttributedString(string: chat.name, attributes: [ .font: UIFont.systemFont(ofSize: 16, weight: .medium) ])
|
|
|
|
|
|
-
|
|
|
if let img = chat.profileImage {
|
|
|
cell.resetBackupImage()
|
|
|
cell.setImage(img)
|
|
@@ -253,6 +254,17 @@ extension ChatListController: UITableViewDataSource, UITableViewDelegate {
|
|
|
return [archive, delete]
|
|
|
}
|
|
|
|
|
|
+ func getDeaddropCell(_ tableView: UITableView) -> ContactCell {
|
|
|
+ let deaddropCell: ContactCell
|
|
|
+ if let cell = tableView.dequeueReusableCell(withIdentifier: "DeaddropCell") as? ContactCell {
|
|
|
+ deaddropCell = cell
|
|
|
+ } else {
|
|
|
+ deaddropCell = ContactCell(style: .default, reuseIdentifier: "DeaddropCell")
|
|
|
+ }
|
|
|
+ deaddropCell.backgroundColor = DcColors.deaddropBackground // TODO: why is the color not changed in darkmode?
|
|
|
+ return deaddropCell
|
|
|
+ }
|
|
|
+
|
|
|
func getArchiveCell(_ tableView: UITableView) -> UITableViewCell {
|
|
|
let archiveCell: UITableViewCell
|
|
|
if let cell = tableView.dequeueReusableCell(withIdentifier: "ArchiveCell") {
|