Skip to content

Commit

Permalink
Show file upscaling progress in Finder
Browse files Browse the repository at this point in the history
  • Loading branch information
finnvoor committed Jun 22, 2024
1 parent b3a76b5 commit 5ecd68a
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Sources/Upscaling/UpscalingExportSession.swift
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ public class UpscalingExportSession {
}
self.outputSize = outputSize
self.creator = creator
progress = Progress(parent: nil, userInfo: [
.fileURLKey: outputURL
])
progress.fileURL = outputURL
progress.isCancellable = false
progress.publish()
}

// MARK: Public
Expand All @@ -36,7 +42,7 @@ public class UpscalingExportSession {
public let outputSize: CGSize
public let creator: String?

public let progress = Progress()
public let progress: Progress

public func export() async throws {
guard !FileManager.default.fileExists(atPath: outputURL.path(percentEncoded: false)) else {
Expand Down

0 comments on commit 5ecd68a

Please sign in to comment.