fix issues after merging

pull/1061/head
Ryan ZHAO 8 months ago
parent b57fbbd32c
commit 082f5b2713

@ -2006,22 +2006,28 @@ extension ConversationVC:
UIPasteboard.general.setData(data, forPasteboardType: type.identifier) UIPasteboard.general.setData(data, forPasteboardType: type.identifier)
} }
self.viewModel.showToast(
text: "copied".localized(), DispatchQueue.main.asyncAfter(deadline: .now() + .milliseconds(Int(ContextMenuVC.dismissDurationPartOne * 1000))) { [weak self] in
backgroundColor: .toast_background, self?.viewModel.showToast(
insect: Values.largeSpacing + (self.inputAccessoryView?.frame.height ?? 0) text: "copied".localized(),
) backgroundColor: .toast_background,
inset: Values.largeSpacing + (self?.inputAccessoryView?.frame.height ?? 0)
)
}
} }
func copySessionID(_ cellViewModel: MessageViewModel) { func copySessionID(_ cellViewModel: MessageViewModel) {
guard cellViewModel.variant == .standardIncoming else { return } guard cellViewModel.variant == .standardIncoming else { return }
UIPasteboard.general.string = cellViewModel.authorId UIPasteboard.general.string = cellViewModel.authorId
self.viewModel.showToast(
text: "copied".localized(), DispatchQueue.main.asyncAfter(deadline: .now() + .milliseconds(Int(ContextMenuVC.dismissDurationPartOne * 1000))) { [weak self] in
backgroundColor: .toast_background, self?.viewModel.showToast(
insect: Values.largeSpacing + (self.inputAccessoryView?.frame.height ?? 0) text: "copied".localized(),
) backgroundColor: .toast_background,
inset: Values.largeSpacing + (self?.inputAccessoryView?.frame.height ?? 0)
)
}
} }
func delete(_ cellViewModel: MessageViewModel) { func delete(_ cellViewModel: MessageViewModel) {
@ -2175,11 +2181,14 @@ extension ConversationVC:
} }
self?.sendDataExtraction(kind: .mediaSaved(timestamp: UInt64(cellViewModel.timestampMs))) self?.sendDataExtraction(kind: .mediaSaved(timestamp: UInt64(cellViewModel.timestampMs)))
self?.viewModel.showToast(
text: "saved".localized(), DispatchQueue.main.asyncAfter(deadline: .now() + .milliseconds(Int(ContextMenuVC.dismissDurationPartOne * 1000))) { [weak self] in
backgroundColor: .toast_background, self?.viewModel.showToast(
insect: Values.largeSpacing + (self?.inputAccessoryView?.frame.height ?? 0) text: "saved".localized(),
) backgroundColor: .toast_background,
inset: Values.largeSpacing + (self?.inputAccessoryView?.frame.height ?? 0)
)
}
} }
} }

Loading…
Cancel
Save