DispatchQueue.main.async
This commit is contained in:
parent
4f8ca8d481
commit
cd6bdead01
|
@ -195,12 +195,12 @@ extension StatusTableViewCellDelegate where Self: DataSourceProvider & AuthConte
|
|||
) { _ in
|
||||
UIPasteboard.general.url = url
|
||||
},
|
||||
|
||||
UIAction(
|
||||
title: L10n.Common.Controls.Actions.share,
|
||||
image: Asset.Arrow.squareAndArrowUp.image.withRenderingMode(.alwaysTemplate)
|
||||
) { _ in
|
||||
Task {
|
||||
await MainActor.run {
|
||||
DispatchQueue.main.async {
|
||||
let activityViewController = UIActivityViewController(
|
||||
activityItems: [
|
||||
URLActivityItemWithMetadata(url: url) { metadata in
|
||||
|
@ -222,14 +222,13 @@ extension StatusTableViewCellDelegate where Self: DataSourceProvider & AuthConte
|
|||
transition: .activityViewControllerPresent(animated: true)
|
||||
)
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
UIAction(
|
||||
title: L10n.Common.Controls.Status.Actions.shareLinkInPost,
|
||||
image: Asset.ObjectsAndTools.squareAndPencil.image.withRenderingMode(.alwaysTemplate)
|
||||
) { _ in
|
||||
Task {
|
||||
await MainActor.run {
|
||||
DispatchQueue.main.async {
|
||||
self.coordinator.present(
|
||||
scene: .compose(viewModel: ComposeViewModel(
|
||||
context: self.context,
|
||||
|
@ -242,7 +241,6 @@ extension StatusTableViewCellDelegate where Self: DataSourceProvider & AuthConte
|
|||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
])
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue