应用程序作为服务运行(mysvc-Windows服务)。它是通过WiX安装程序使用 func assetsPicker(controller: AssetsPickerViewController, selected assets: [PHAsset]) {
if assets[0].mediaType == .video{
let options: PHVideoRequestOptions = PHVideoRequestOptions()
options.version = .original
options.isNetworkAccessAllowed = true
self.showLoaderView()
for i in 0..<self.assets.count {
let videos = VideoFileModel()
PHImageManager.default().requestAVAsset(forVideo: self.assets[i] , options: options, resultHandler: { (asset, audioMix, info) in
let urlAsset = asset as! AVURLAsset
DispatchQueue.main.async {
let localVideoUrl = urlAsset.url
var frameRate = CGSize()
frameRate = self.resolutionForLocalVideo(url: localVideoUrl)!
let actualFrameRate = CGSize(width: 1280, height: 720)
if frameRate.equalTo(actualFrameRate){
//resolutions are equal (don't have to resize)
}
else{
//resolutions are not equal (resize to 1280 X 720)
}
self.loadingLayerView.removeFromSuperview()
}
}
wix标记安装的。它会成功升级 InstallServices
。
现在,我要进行一些DeInit / Cleanup,安排mysvc上的升级活动。
那么服务mysvc可以在WiX升级启动之前检测到升级吗?