Commit cb73e88f authored by CZ1004's avatar CZ1004

【修复】修复压缩进程BUG

parent 2e214446
......@@ -46,6 +46,7 @@ class CompressingViewController: BaseViewController {
}()
let alert = EmailContentDelAlert(state: .endCompress)
var alertShow : Bool = false
lazy var animationView : LottieAnimationView = {
let animationView = LottieAnimationView(name: "iOS压缩完成")
......@@ -107,6 +108,7 @@ class CompressingViewController: BaseViewController {
self.view.hideBlur()
}
self.alert.show()
self.alertShow = true
}
setUI()
......@@ -196,18 +198,26 @@ class CompressingViewController: BaseViewController {
/// - comVideoDataSource: 压缩后的视频链接数组
fileprivate func updateNextView(_ compressAllSize: Double,_ comDataSource : [Data],_ comVideoDataSource : [URL]) {
DispatchQueue.main.async {
self.view.hideBlur()
self.alert.dismiss(animated: true) {
let vc = CompressCompletedViewController()
vc.currentMediaType = self.currentMediaType
vc.comDataSource = comDataSource
vc.comVideoDataSource = comVideoDataSource
vc.model = self.model
vc.completedSize = compressAllSize
self.navigationController?.pushViewController(vc, animated: true)
if self.alertShow {
self.view.hideBlur()
self.alert.dismiss(animated: true) {
self.jumpNextPage(compressAllSize,comDataSource,comVideoDataSource)
}
}else {
self.jumpNextPage(compressAllSize,comDataSource,comVideoDataSource)
}
}
}
func jumpNextPage(_ compressAllSize: Double,_ comDataSource : [Data],_ comVideoDataSource : [URL]){
let vc = CompressCompletedViewController()
vc.currentMediaType = self.currentMediaType
vc.comDataSource = comDataSource
vc.comVideoDataSource = comVideoDataSource
vc.model = self.model
vc.completedSize = compressAllSize
self.navigationController?.pushViewController(vc, animated: true)
}
// MARK: 设置UI
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment